[-] Installer: Fix 2 path for the upgrader
This commit is contained in:
@@ -48,9 +48,9 @@ function editorial_update()
|
|||||||
PRIMARY KEY (`id_editorial`, `id_lang`))
|
PRIMARY KEY (`id_editorial`, `id_lang`))
|
||||||
ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8');
|
ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8');
|
||||||
|
|
||||||
if (file_exists(dirname(__FILE__).'/../../modules/editorial/editorial.xml'))
|
if (file_exists(dirname(__FILE__).'/../../../modules/editorial/editorial.xml'))
|
||||||
{
|
{
|
||||||
$xml = simplexml_load_file(dirname(__FILE__).'/../../modules/editorial/editorial.xml');
|
$xml = simplexml_load_file(dirname(__FILE__).'/../../../modules/editorial/editorial.xml');
|
||||||
Db::getInstance()->execute('
|
Db::getInstance()->execute('
|
||||||
INSERT INTO `'._DB_PREFIX_.'editorial`(`id_editorial`, `body_home_logo_link`) VALUES(1, "'.(isset($xml->body->home_logo_link) ? pSQL($xml->body->home_logo_link) : '').'")');
|
INSERT INTO `'._DB_PREFIX_.'editorial`(`id_editorial`, `body_home_logo_link`) VALUES(1, "'.(isset($xml->body->home_logo_link) ? pSQL($xml->body->home_logo_link) : '').'")');
|
||||||
|
|
||||||
@@ -65,7 +65,7 @@ function editorial_update()
|
|||||||
"'.(isset($xml->body->{'paragraph_'.$language['id_lang']}) ? pSQL($xml->body->{'paragraph_'.$language['id_lang']}, true) : '').'",
|
"'.(isset($xml->body->{'paragraph_'.$language['id_lang']}) ? pSQL($xml->body->{'paragraph_'.$language['id_lang']}, true) : '').'",
|
||||||
"'.(isset($xml->body->{'logo_subheading_'.$language['id_lang']}) ? pSQL($xml->body->{'logo_subheading_'.$language['id_lang']}) : '').'")');
|
"'.(isset($xml->body->{'logo_subheading_'.$language['id_lang']}) ? pSQL($xml->body->{'logo_subheading_'.$language['id_lang']}) : '').'")');
|
||||||
|
|
||||||
unlink(dirname(__FILE__).'/../../modules/editorial/editorial.xml');
|
unlink(dirname(__FILE__).'/../../../modules/editorial/editorial.xml');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ function gridextjs_deprecated()
|
|||||||
if (defined('_PS_ROOT_DIR_'))
|
if (defined('_PS_ROOT_DIR_'))
|
||||||
$gridextjs_path = _PS_ROOT_DIR_ . '/modules/gridextjs';
|
$gridextjs_path = _PS_ROOT_DIR_ . '/modules/gridextjs';
|
||||||
else
|
else
|
||||||
$gridextjs_path = dirname(__FILE__).'/../../modules/gridextjs';
|
$gridextjs_path = dirname(__FILE__).'/../../../modules/gridextjs';
|
||||||
|
|
||||||
if (file_exists($gridextjs_path))
|
if (file_exists($gridextjs_path))
|
||||||
return rename($gridextjs_path, str_replace('gridextjs', 'gridextjs.deprecated', $gridextjs_path));
|
return rename($gridextjs_path, str_replace('gridextjs', 'gridextjs.deprecated', $gridextjs_path));
|
||||||
|
|||||||
Reference in New Issue
Block a user