// Some security stuff...
if (!defined('__SECURITY')) {
die();
+} elseif (isInstallationPhase()) {
+ // Use this code if you don't want to run this cache loader on installation phase
+ return;
} elseif (!isExtensionActive('theme')) {
// Skip this loader
return false;
}
-// Use this code if you don't want to run this cache loader on installation phase
-if (isInstallationPhase()) return;
-
// Next cached table is the referal system (themes)...
if (($GLOBALS['cache_instance']->loadCacheFile('themes')) && ($GLOBALS['cache_instance']->extensionVersionMatches('theme'))) {
// Load referal system from cache
// Load all themes and their data
if (isExtensionInstalledAndNewer('theme', '0.0.7')) {
- $result = SQL_QUERY('SELECT id, theme_path, theme_active, theme_ver, theme_name FROM `{?_MYSQL_PREFIX?}_themes` ORDER BY `id`', __FILE__, __LINE__);
+ $result = SQL_QUERY('SELECT `id`,`theme_path`,`theme_active`,`theme_ver`,`theme_name` FROM `{?_MYSQL_PREFIX?}_themes` ORDER BY `id` ASC', __FILE__, __LINE__);
} else {
- $result = SQL_QUERY('SELECT id, theme_path, theme_active, theme_ver FROM `{?_MYSQL_PREFIX?}_themes` ORDER BY `id`', __FILE__, __LINE__);
+ $result = SQL_QUERY('SELECT `id`,`theme_path`,`theme_active`,`theme_ver` FROM `{?_MYSQL_PREFIX?}_themes` ORDER BY `id` ASC', __FILE__, __LINE__);
}
while ($content = SQL_FETCHARRAY($result)) {
// Add row to cache file