]> git.mxchange.org Git - mailer.git/blobdiff - inc/loader/load-themes.php
Extension ext-forced continued:
[mailer.git] / inc / loader / load-themes.php
index 0deca53068072853d9d0a80176db761028065807..8f06873a0f2769f9ec009e189d92bda002d40cae 100644 (file)
 // 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
@@ -76,9 +76,9 @@ if (($GLOBALS['cache_instance']->loadCacheFile('themes')) && ($GLOBALS['cache_in
 
        // 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