forked from magepow/magento-2-programmatically
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathupdateConfig.php
More file actions
21 lines (17 loc) · 734 Bytes
/
updateConfig.php
File metadata and controls
21 lines (17 loc) · 734 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<?php
require dirname(__FILE__) . '/app/bootstrap.php';
$bootstrap = \Magento\Framework\App\Bootstrap::create(BP, $_SERVER);
class Outslide extends \Magento\Framework\App\Http
implements \Magento\Framework\AppInterface {
public function launch()
{
$config = $this->_objectManager->create('\Magento\Config\Model\ResourceModel\Config');
$config->saveConfig('web/unsecure/base_url', 'http://magepow.com/',\Magento\Framework\App\Config\ScopeConfigInterface::SCOPE_TYPE_DEFAULT,0);
echo 'Done!';
//the method must end with this line
return $this->_response;
}
}
/** @var \Magento\Framework\App\Http $app */
$app = $bootstrap->createApplication('Outslide');
$bootstrap->run($app);