This commit is contained in:
aFolletete
2011-04-25 12:07:31 +00:00
parent e45a1fe324
commit 37130dd53c
4 changed files with 7 additions and 14 deletions
+3 -3
View File
@@ -49,18 +49,18 @@ class AdminHome extends AdminTab
$htaccessAfterUpdate = 2;
$htaccessOptimized = (Configuration::get('PS_HTACCESS_CACHE_CONTROL') ? 2 : 0);
if (!file_exists(dirname(__FILE__).'/../.htaccess'))
if (!file_exists(dirname(__FILE__).'/../../.htaccess'))
{
if (Configuration::get('PS_HTACCESS_CACHE_CONTROL'))
$htaccessOptimized = 1;
}
else
{
$stat = stat(dirname(__FILE__).'/../.htaccess');
$stat = stat(dirname(__FILE__).'/../../.htaccess');
$dateUpdHtaccess = Db::getInstance()->getValue('SELECT date_upd FROM '._DB_PREFIX_.'configuration WHERE name = "PS_HTACCESS_CACHE_CONTROL"');
if (Configuration::get('PS_HTACCESS_CACHE_CONTROL') AND strtotime($dateUpdHtaccess) > $stat['mtime'])
$htaccessOptimized = 1;
$dateUpdate = Configuration::get('PS_LAST_SHOP_UPDATE');
if ($dateUpdate AND strtotime($dateUpdate) > $stat['mtime'])
$htaccessAfterUpdate = 0;