Index: trunk/kernel/units/general/helpers/modules.php =================================================================== diff -u -N -r4591 -r4592 --- trunk/kernel/units/general/helpers/modules.php (.../modules.php) (revision 4591) +++ trunk/kernel/units/general/helpers/modules.php (.../modules.php) (revision 4592) @@ -11,7 +11,7 @@ { $where_clause = Array('Loaded = 1'); - if (!$this->Application->IsAdmin()) return $where_clause; + if (!$this->Application->IsAdmin()) return implode(' AND ', $where_clause); $modules = $this->_GetModules(); if ($modules) { @@ -21,7 +21,7 @@ $where_clause[] = 'Name IN ('.implode(',', $modules).')'; } - return $where_clause; + return implode(' AND ', $where_clause); } function _EnableCookieSID() Index: trunk/core/kernel/application.php =================================================================== diff -u -N -r4591 -r4592 --- trunk/core/kernel/application.php (.../application.php) (revision 4591) +++ trunk/core/kernel/application.php (.../application.php) (revision 4592) @@ -243,7 +243,7 @@ $modules_helper =& $this->recallObject('ModulesHelper'); $sql = 'SELECT * FROM '.TABLE_PREFIX.'Modules - WHERE '.implode(' AND ', $modules_helper->getWhereClause()).' + WHERE '.$modules_helper->getWhereClause().' ORDER BY LoadOrder'; $this->ModuleInfo = $this->Conn->Query($sql, 'Name'); Index: trunk/core/units/general/helpers/modules.php =================================================================== diff -u -N -r4591 -r4592 --- trunk/core/units/general/helpers/modules.php (.../modules.php) (revision 4591) +++ trunk/core/units/general/helpers/modules.php (.../modules.php) (revision 4592) @@ -11,7 +11,7 @@ { $where_clause = Array('Loaded = 1'); - if (!$this->Application->IsAdmin()) return $where_clause; + if (!$this->Application->IsAdmin()) return implode(' AND ', $where_clause); $modules = $this->_GetModules(); if ($modules) { @@ -21,7 +21,7 @@ $where_clause[] = 'Name IN ('.implode(',', $modules).')'; } - return $where_clause; + return implode(' AND ', $where_clause); } function _EnableCookieSID()