Index: core/install.php =================================================================== --- core/install.php (revision 15000) +++ core/install.php (working copy) @@ -387,6 +387,13 @@ break; case 'install_setup': + if ( $this->Application->TableFound(TABLE_PREFIX . 'UserSession', true) ) { + // update to 5.2.0 -> rename session table before using it + // don't rename any other table here, since their names could be used in upgrade script + $this->Conn->Query('RENAME TABLE ' . TABLE_PREFIX . 'UserSession TO ' . TABLE_PREFIX . 'UserSessions'); + $this->Conn->Query('RENAME TABLE ' . TABLE_PREFIX . 'SessionData TO ' . TABLE_PREFIX . 'UserSessionData'); + } + $next_preset = $this->Application->GetVar('next_preset'); if ($next_preset !== false) { $user_helper =& $this->Application->recallObject('UserHelper'); @@ -651,7 +658,7 @@ 'l1_Description' => 'Content', 'Status' => 4, ); - $this->Conn->doInsert($fields_hash, $this->toolkit->getSystemConfig('Database', 'TablePrefix') . 'Category'); + $this->Conn->doInsert($fields_hash, $this->toolkit->getSystemConfig('Database', 'TablePrefix') . 'Categories'); $this->toolkit->SetModuleRootCategory('Core', $this->Conn->getInsertID()); @@ -1042,7 +1049,7 @@ 'VariableName' => 'InstallFinished', 'VariableValue' => 1, ); - $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'ConfigurationValues'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'SystemSettings'); } break; } @@ -1343,12 +1350,13 @@ function AlreadyInstalled() { $table_prefix = $this->toolkit->getSystemConfig('Database', 'TablePrefix'); + $settings_table = $this->TableExists('ConfigurationValues') ? 'ConfigurationValues' : 'SystemSettings'; $sql = 'SELECT VariableValue - FROM ' . $table_prefix . 'ConfigurationValues + FROM ' . $table_prefix . $settings_table . ' WHERE VariableName = "InstallFinished"'; - return $this->TableExists('ConfigurationValues') && $this->Conn->GetOne($sql); + return $this->TableExists($settings_table) && $this->Conn->GetOne($sql); } function CheckDatabase($check_installed = true) Index: core/install/install_data.sql =================================================================== --- core/install/install_data.sql (revision 14994) +++ core/install/install_data.sql (working copy) @@ -1,191 +1,191 @@ # Section "in-portal:configure_categories": -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_Sortfield', 'Name', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield_prompt', 'select', '', 'Name=la_opt_Title||Description=la_opt_Description||CreatedOn=la_opt_CreatedOn||EditorsPick=la_opt_EditorsPick||SELECT Prompt AS OptionName, CONCAT("cust_", FieldName) AS OptionValue FROM CustomField WHERE (Type = 1) AND (IsSystem = 0)', 10.01, 1, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_Sortorder', 'asc', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield_prompt', 'select', '', 'asc=la_common_Ascending||desc=la_common_Descending', 10.01, 2, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_Sortfield2', 'Description', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield2_prompt', 'select', '', 'Name=la_opt_Title||Description=la_opt_Description||CreatedOn=la_opt_CreatedOn||EditorsPick=la_opt_EditorsPick||SELECT Prompt AS OptionName, CONCAT("cust_", FieldName) AS OptionValue FROM CustomField WHERE (Type = 1) AND (IsSystem = 0)', 10.02, 1, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_Sortorder2', 'asc', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield2_prompt', 'select', '', 'asc=la_common_Ascending||desc=la_common_Descending', 10.02, 2, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Perpage_Category', '20', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_perpage_prompt', 'text', '', '', 10.03, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Perpage_Category_Short', '3', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_perpage__short_prompt', 'text', '', '', 10.04, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_DaysNew', '8', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_daysnew_prompt', 'text', '', '', 10.05, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_ShowPick', '', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_showpick_prompt', 'checkbox', '', '', 10.06, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MaxImportCategoryLevels', '10', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_prompt_max_import_category_levels', 'text', '', '', 10.07, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'AllowDeleteRootCats', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_AllowDeleteRootCats', 'checkbox', NULL, NULL, 10.08, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Catalog_PreselectModuleTab', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_CatalogPreselectModuleTab', 'checkbox', NULL, NULL, 10.09, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'RecycleBinFolder', '', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_RecycleBinFolder', 'text', NULL, NULL, 10.10, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'QuickCategoryPermissionRebuild', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_QuickCategoryPermissionRebuild', 'checkbox', NULL, NULL, 10.11, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'FilenameSpecialCharReplacement', '-', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_FilenameSpecialCharReplacement', 'select', NULL, '_=+_||-=+-', 10.12, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Search_MinKeyword_Length', '3', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_Search_MinKeyword_Length', 'text', NULL, NULL, 10.13, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'ExcludeTemplateSectionsFromSearch', '0', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_ExcludeTemplateSectionsFromSearch', 'checkbox', '', '', 10.14, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UpdateCountersOnFilterChange', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_UpdateCountersOnFilterChange', 'checkbox', '', '', 10.15, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_MetaKey', '', 'In-Portal', 'in-portal:configure_categories', 'la_Text_MetaInfo', 'la_category_metakey', 'textarea', '', '', 20.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Category_MetaDesc', '', 'In-Portal', 'in-portal:configure_categories', 'la_Text_MetaInfo', 'la_category_metadesc', 'textarea', '', '', 20.02, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_Sortfield', 'Name', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield_prompt', 'select', '', 'Name=la_opt_Title||Description=la_opt_Description||CreatedOn=la_opt_CreatedOn||EditorsPick=la_opt_EditorsPick||SELECT Prompt AS OptionName, CONCAT("cust_", FieldName) AS OptionValue FROM CustomFields WHERE (Type = 1) AND (IsSystem = 0)', 10.01, 1, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_Sortorder', 'asc', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield_prompt', 'select', '', 'asc=la_common_Ascending||desc=la_common_Descending', 10.01, 2, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_Sortfield2', 'Description', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield2_prompt', 'select', '', 'Name=la_opt_Title||Description=la_opt_Description||CreatedOn=la_opt_CreatedOn||EditorsPick=la_opt_EditorsPick||SELECT Prompt AS OptionName, CONCAT("cust_", FieldName) AS OptionValue FROM CustomFields WHERE (Type = 1) AND (IsSystem = 0)', 10.02, 1, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_Sortorder2', 'asc', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_sortfield2_prompt', 'select', '', 'asc=la_common_Ascending||desc=la_common_Descending', 10.02, 2, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Perpage_Category', '20', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_perpage_prompt', 'text', '', '', 10.03, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Perpage_Category_Short', '3', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_perpage__short_prompt', 'text', '', '', 10.04, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_DaysNew', '8', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_daysnew_prompt', 'text', '', '', 10.05, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_ShowPick', '', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_category_showpick_prompt', 'checkbox', '', '', 10.06, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MaxImportCategoryLevels', '10', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_prompt_max_import_category_levels', 'text', '', '', 10.07, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'AllowDeleteRootCats', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_AllowDeleteRootCats', 'checkbox', NULL, NULL, 10.08, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Catalog_PreselectModuleTab', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_CatalogPreselectModuleTab', 'checkbox', NULL, NULL, 10.09, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'RecycleBinFolder', '', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_RecycleBinFolder', 'text', NULL, NULL, 10.10, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'QuickCategoryPermissionRebuild', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_QuickCategoryPermissionRebuild', 'checkbox', NULL, NULL, 10.11, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'FilenameSpecialCharReplacement', '-', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_FilenameSpecialCharReplacement', 'select', NULL, '_=+_||-=+-', 10.12, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Search_MinKeyword_Length', '3', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_Search_MinKeyword_Length', 'text', NULL, NULL, 10.13, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'ExcludeTemplateSectionsFromSearch', '0', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_ExcludeTemplateSectionsFromSearch', 'checkbox', '', '', 10.14, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UpdateCountersOnFilterChange', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_UpdateCountersOnFilterChange', 'checkbox', '', '', 10.15, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_MetaKey', '', 'In-Portal', 'in-portal:configure_categories', 'la_Text_MetaInfo', 'la_category_metakey', 'textarea', '', '', 20.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Category_MetaDesc', '', 'In-Portal', 'in-portal:configure_categories', 'la_Text_MetaInfo', 'la_category_metadesc', 'textarea', '', '', 20.02, 0, 1, NULL); # Section "in-portal:configure_general": -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Site_Name', 'In-Portal CMS', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsWebsite', 'la_config_website_name', 'text', '', '', 10.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'FirstDayOfWeek', '1', 'In-Portal', 'in-portal:configure_general', 'la_Text_Date_Time_Settings', 'la_config_first_day_of_week', 'select', '', '0=la_sunday||1=la_monday', 20.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Config_Site_Time', '', 'In-Portal', 'in-portal:configure_general', 'la_Text_Date_Time_Settings', 'la_config_site_zone', 'select', '', NULL, 20.02, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'DefaultEmailSender', 'portal@user.domain.name', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsMailling', 'la_prompt_AdminMailFrom', 'text', NULL, 'size="40"', 30.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SessionTimeout', '3600', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsSession', 'la_prompt_session_timeout', 'text', 'a:3:{s:4:"type";s:3:"int";s:13:"min_value_inc";i:1;s:8:"required";i:1;}', '', 40.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'AdminConsoleInterface', 'simple', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsAdmin', 'la_config_AdminConsoleInterface', 'select', '', 'simple=+simple||advanced=+advanced||custom=+custom', 50.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Site_Name', 'In-Portal CMS', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsWebsite', 'la_config_website_name', 'text', '', '', 10.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'FirstDayOfWeek', '1', 'In-Portal', 'in-portal:configure_general', 'la_Text_Date_Time_Settings', 'la_config_first_day_of_week', 'select', '', '0=la_sunday||1=la_monday', 20.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Config_Site_Time', '', 'In-Portal', 'in-portal:configure_general', 'la_Text_Date_Time_Settings', 'la_config_site_zone', 'select', '', NULL, 20.02, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'DefaultEmailSender', 'portal@user.domain.name', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsMailling', 'la_prompt_AdminMailFrom', 'text', NULL, 'size="40"', 30.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SessionTimeout', '3600', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsSession', 'la_prompt_session_timeout', 'text', 'a:3:{s:4:"type";s:3:"int";s:13:"min_value_inc";i:1;s:8:"required";i:1;}', '', 40.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'AdminConsoleInterface', 'simple', 'In-Portal', 'in-portal:configure_general', 'la_section_SettingsAdmin', 'la_config_AdminConsoleInterface', 'select', '', 'simple=+simple||advanced=+advanced||custom=+custom', 50.01, 0, 1, NULL); # Section "in-portal:configure_advanced": -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'PageHitCounter', '0', 'In-Portal', 'in-portal:configure_advanced', '', '', '', NULL, NULL, 0, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseModRewrite', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_use_modrewrite', 'checkbox', '', '', 10.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'ModRewriteUrlEnding', '.html', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_ModRewriteUrlEnding', 'select', '', '=+||/=+/||.html=+.html', 10.011, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'ForceModRewriteUrlEnding', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_ForceModRewriteUrlEnding', 'checkbox', '', NULL, 10.012, 0, 0, 'hint:la_config_ForceModRewriteUrlEnding'); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseContentLanguageNegotiation', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_UseContentLanguageNegotiation', 'checkbox', '', '', 10.013, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'cms_DefaultDesign', '#default_design#', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_DefaultDesignTemplate', 'text', NULL, NULL, 10.02, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'ErrorTemplate', 'error_notfound', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_error_template', 'text', '', '', 10.03, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'NoPermissionTemplate', 'no_permission', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_nopermission_template', 'text', '', '', 10.04, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UsePageHitCounter', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_UsePageHitCounter', 'checkbox', '', '', 10.05, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'ForceImageMagickResize', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_ForceImageMagickResize', 'checkbox', '', '', 10.06, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'CheckStopWords', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_CheckStopWords', 'checkbox', '', '', 10.07, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseVisitorTracking', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_UseVisitorTracking', 'checkbox', '', '', 10.08, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'cms_DefaultTrackingCode', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_DefaultTrackingCode', 'textarea', NULL, 'COLS=40 ROWS=5', 10.09, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'PerformExactSearch', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_PerformExactSearch', 'checkbox', '', '', '10.10', 0, 0, 'hint:la_config_PerformExactSearch'); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MaintenanceMessageFront', 'Website is currently undergoing the upgrades. Please come back shortly!', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_MaintenanceMessageFront', 'textarea', '', 'style="width: 100%; height: 100px;"', '15.01', 0, 0, 'hint:la_config_MaintenanceMessageFront'); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MaintenanceMessageAdmin', 'Website is currently undergoing the upgrades. Please come back shortly!', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_MaintenanceMessageAdmin', 'textarea', '', 'style="width: 100%; height: 100px;"', '15.02', 0, 0, 'hint:la_config_MaintenanceMessageAdmin'); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SoftMaintenanceTemplate', 'maintenance', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_SoftMaintenanceTemplate', 'text', '', 'style="width: 200px;"', '15.03', 0, 0, 'hint:la_config_SoftMaintenanceTemplate'); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'HardMaintenanceTemplate', 'maintenance', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_HardMaintenanceTemplate', 'text', '', 'style="width: 200px;"', '15.04', 0, 0, 'hint:la_config_HardMaintenanceTemplate'); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'CookieSessions', '2', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_prompt_session_management', 'select', NULL, '0=lu_opt_QueryString||1=lu_opt_Cookies||2=lu_opt_AutoDetect', 20.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SessionCookieName', 'sid', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_prompt_session_cookie_name', 'text', '', '', 20.02, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SessionCookieDomains', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_SessionCookieDomains', 'textarea', '', 'rows="5" cols="40"', 20.021, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'KeepSessionOnBrowserClose', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_KeepSessionOnBrowserClose', 'checkbox', '', '', 20.03, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SessionBrowserSignatureCheck', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_SessionBrowserSignatureCheck', 'checkbox', NULL, NULL, 20.04, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SessionIPAddressCheck', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_SessionIPAddressCheck', 'checkbox', NULL, NULL, 20.05, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseJSRedirect', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_use_js_redirect', 'checkbox', '', '', 20.06, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SSL_URL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_ssl_url', 'text', '', '', 30.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'AdminSSL_URL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_AdminSSL_URL', 'text', '', '', 30.02, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Require_SSL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_require_ssl', 'checkbox', '', '', 30.03, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Require_AdminSSL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_RequireSSLAdmin', 'checkbox', '', '', 30.04, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Force_HTTP_When_SSL_Not_Required', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_force_http', 'checkbox', '', '', 30.04, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseModRewriteWithSSL', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_use_modrewrite_with_ssl', 'checkbox', '', '', 30.06, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'RootPass', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_prompt_root_pass', 'password', NULL, NULL, 40.01, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'AllowAdminConsoleInterfaceChange', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_AllowAdminConsoleInterfaceChange', 'checkbox', NULL, NULL, 40.02, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseToolbarLabels', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseToolbarLabels', 'checkbox', NULL, NULL, 40.03, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseSmallHeader', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseSmallHeader', 'checkbox', '', '', 40.04, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseColumnFreezer', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseColumnFreezer', 'checkbox', '', '', 40.05, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UsePopups', '2', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UsePopups', 'select', '', '0=la_opt_SameWindow||1=la_opt_PopupWindow||2=la_opt_ModalWindow', 40.06, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'StickyGridSelection', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_StickyGridSelection', 'radio', '', '1=la_Yes||0=la_No', 40.07, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseDoubleSorting', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseDoubleSorting', 'radio', '', '1=la_Yes||0=la_No', 40.08, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MenuFrameWidth', '200', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_prompt_MenuFrameWidth', 'text', NULL, NULL, 40.09, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'ResizableFrames', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_ResizableFrames', 'checkbox', '', '', 40.10, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'AutoRefreshIntervals', '1,5,15,30,60,120,240', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_AutoRefreshIntervals', 'text', '', '', 40.11, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'DebugOnlyFormConfigurator', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_DebugOnlyFormConfigurator', 'checkbox', '', '', 40.12, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'DebugOnlyPromoBlockGroupConfigurator', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_DebugOnlyPromoBlockGroupConfigurator', 'checkbox', '', '', 40.13, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'RememberLastAdminTemplate', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_RememberLastAdminTemplate', 'checkbox', '', '', 40.14, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseHTTPAuth', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseHTTPAuth', 'checkbox', '', '', 40.15, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'HTTPAuthUsername', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_HTTPAuthUsername', 'text', '', '', 40.16, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'HTTPAuthPassword', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_HTTPAuthPassword', 'password', NULL, NULL, 40.17, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'HTTPAuthBypassIPs', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_HTTPAuthBypassIPs', 'text', '', '', 40.18, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Smtp_Server', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_mailserver', 'text', NULL, NULL, 50.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Smtp_Port', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_mailport', 'text', NULL, NULL, 50.02, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Smtp_Authenticate', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_mailauthenticate', 'checkbox', NULL, NULL, 50.03, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Smtp_User', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_smtp_user', 'text', NULL, NULL, 50.04, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Smtp_Pass', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_smtp_pass', 'text', NULL, NULL, 50.05, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Smtp_DefaultHeaders', 'X-Mailer: In-Portal', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_smtpheaders', 'textarea', NULL, 'COLS=40 ROWS=5', 50.06, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MailFunctionHeaderSeparator', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_MailFunctionHeaderSeparator', 'radio', NULL, '1=la_Linux||2=la_Windows', 50.07, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MailingListQueuePerStep', '10', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_MailingListQueuePerStep', 'text', NULL, NULL, 50.08, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MailingListSendPerStep', '10', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_MailingListSendPerStep', 'text', NULL, NULL, 50.09, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'DefaultEmailRecipients', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_DefaultEmailRecipients', 'text', NULL, NULL, 50.10, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseOutputCompression', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_UseOutputCompression', 'checkbox', '', '', 60.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'OutputCompressionLevel', '7', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_OutputCompressionLevel', 'text', '', '', 60.02, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseTemplateCompression', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_UseTemplateCompression', 'checkbox', '', '', 60.03, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'TrimRequiredFields', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_TrimRequiredFields', 'checkbox', '', '', 60.04, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'RunScheduledTasksFromCron', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_UseCronForRegularEvent', 'checkbox', NULL, NULL, 60.05, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UseChangeLog', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_UseChangeLog', 'checkbox', '', '', 60.06, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Backup_Path', '/home/alex/web/in-portal.rc/system/backupdata', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_backup_path', 'text', '', '', 60.07, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SystemTagCache', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_prompt_syscache_enable', 'checkbox', NULL, NULL, 60.08, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SocketBlockingMode', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_prompt_socket_blocking_mode', 'checkbox', NULL, NULL, 60.09, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'CSVExportDelimiter', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportDelimiter', 'select', NULL, '0=la_opt_Tab||1=la_opt_Comma||2=la_opt_Semicolon||3=la_opt_Space||4=la_opt_Colon', 70.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'CSVExportEnclosure', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportEnclosure', 'radio', NULL, '0=la_Doublequotes||1=la_Quotes', 70.02, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'CSVExportSeparator', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportSeparator', 'radio', NULL, '0=la_Linux||1=la_Windows', 70.03, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'CSVExportEncoding', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportEncoding', 'radio', NULL, '0=la_Unicode||1=la_Regular', 70.04, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'YahooApplicationId', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_Settings3rdPartyAPI', 'la_config_YahooApplicationId', 'text', NULL, NULL, 80.01, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'l_GoogleMapsAPIKey', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_Settings3rdPartyAPI', 'la_fld_LinkGoogleMapsAPIKey', 'text', NULL, NULL, 80.02, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'PageHitCounter', '0', 'In-Portal', 'in-portal:configure_advanced', '', '', '', NULL, NULL, 0, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseModRewrite', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_use_modrewrite', 'checkbox', '', '', 10.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'ModRewriteUrlEnding', '.html', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_ModRewriteUrlEnding', 'select', '', '=+||/=+/||.html=+.html', 10.011, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'ForceModRewriteUrlEnding', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_ForceModRewriteUrlEnding', 'checkbox', '', NULL, 10.012, 0, 0, 'hint:la_config_ForceModRewriteUrlEnding'); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseContentLanguageNegotiation', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_UseContentLanguageNegotiation', 'checkbox', '', '', 10.013, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'cms_DefaultDesign', '#default_design#', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_DefaultDesignTemplate', 'text', NULL, NULL, 10.02, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'ErrorTemplate', 'error_notfound', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_error_template', 'text', '', '', 10.03, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'NoPermissionTemplate', 'no_permission', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_nopermission_template', 'text', '', '', 10.04, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UsePageHitCounter', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_UsePageHitCounter', 'checkbox', '', '', 10.05, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'ForceImageMagickResize', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_ForceImageMagickResize', 'checkbox', '', '', 10.06, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'CheckStopWords', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_CheckStopWords', 'checkbox', '', '', 10.07, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseVisitorTracking', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_UseVisitorTracking', 'checkbox', '', '', 10.08, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'cms_DefaultTrackingCode', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_DefaultTrackingCode', 'textarea', NULL, 'COLS=40 ROWS=5', 10.09, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'PerformExactSearch', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsWebsite', 'la_config_PerformExactSearch', 'checkbox', '', '', '10.10', 0, 0, 'hint:la_config_PerformExactSearch'); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MaintenanceMessageFront', 'Website is currently undergoing the upgrades. Please come back shortly!', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_MaintenanceMessageFront', 'textarea', '', 'style="width: 100%; height: 100px;"', '15.01', 0, 0, 'hint:la_config_MaintenanceMessageFront'); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MaintenanceMessageAdmin', 'Website is currently undergoing the upgrades. Please come back shortly!', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_MaintenanceMessageAdmin', 'textarea', '', 'style="width: 100%; height: 100px;"', '15.02', 0, 0, 'hint:la_config_MaintenanceMessageAdmin'); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SoftMaintenanceTemplate', 'maintenance', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_SoftMaintenanceTemplate', 'text', '', 'style="width: 200px;"', '15.03', 0, 0, 'hint:la_config_SoftMaintenanceTemplate'); +INSERT INTO SystemSettings VALUES(DEFAULT, 'HardMaintenanceTemplate', 'maintenance', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMaintenance', 'la_config_HardMaintenanceTemplate', 'text', '', 'style="width: 200px;"', '15.04', 0, 0, 'hint:la_config_HardMaintenanceTemplate'); +INSERT INTO SystemSettings VALUES(DEFAULT, 'CookieSessions', '2', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_prompt_session_management', 'select', NULL, '0=lu_opt_QueryString||1=lu_opt_Cookies||2=lu_opt_AutoDetect', 20.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SessionCookieName', 'sid', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_prompt_session_cookie_name', 'text', '', '', 20.02, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SessionCookieDomains', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_SessionCookieDomains', 'textarea', '', 'rows="5" cols="40"', 20.021, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'KeepSessionOnBrowserClose', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_KeepSessionOnBrowserClose', 'checkbox', '', '', 20.03, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SessionBrowserSignatureCheck', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_SessionBrowserSignatureCheck', 'checkbox', NULL, NULL, 20.04, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SessionIPAddressCheck', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_SessionIPAddressCheck', 'checkbox', NULL, NULL, 20.05, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseJSRedirect', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSession', 'la_config_use_js_redirect', 'checkbox', '', '', 20.06, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SSL_URL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_ssl_url', 'text', '', '', 30.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'AdminSSL_URL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_AdminSSL_URL', 'text', '', '', 30.02, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Require_SSL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_require_ssl', 'checkbox', '', '', 30.03, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Require_AdminSSL', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_RequireSSLAdmin', 'checkbox', '', '', 30.04, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Force_HTTP_When_SSL_Not_Required', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_force_http', 'checkbox', '', '', 30.04, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseModRewriteWithSSL', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSSL', 'la_config_use_modrewrite_with_ssl', 'checkbox', '', '', 30.06, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'RootPass', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_prompt_root_pass', 'password', NULL, NULL, 40.01, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'AllowAdminConsoleInterfaceChange', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_AllowAdminConsoleInterfaceChange', 'checkbox', NULL, NULL, 40.02, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseToolbarLabels', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseToolbarLabels', 'checkbox', NULL, NULL, 40.03, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseSmallHeader', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseSmallHeader', 'checkbox', '', '', 40.04, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseColumnFreezer', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseColumnFreezer', 'checkbox', '', '', 40.05, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UsePopups', '2', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UsePopups', 'select', '', '0=la_opt_SameWindow||1=la_opt_PopupWindow||2=la_opt_ModalWindow', 40.06, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'StickyGridSelection', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_StickyGridSelection', 'radio', '', '1=la_Yes||0=la_No', 40.07, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseDoubleSorting', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseDoubleSorting', 'radio', '', '1=la_Yes||0=la_No', 40.08, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MenuFrameWidth', '200', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_prompt_MenuFrameWidth', 'text', NULL, NULL, 40.09, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'ResizableFrames', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_ResizableFrames', 'checkbox', '', '', 40.10, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'AutoRefreshIntervals', '1,5,15,30,60,120,240', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_AutoRefreshIntervals', 'text', '', '', 40.11, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'DebugOnlyFormConfigurator', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_DebugOnlyFormConfigurator', 'checkbox', '', '', 40.12, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'DebugOnlyPromoBlockGroupConfigurator', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_DebugOnlyPromoBlockGroupConfigurator', 'checkbox', '', '', 40.13, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'RememberLastAdminTemplate', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_RememberLastAdminTemplate', 'checkbox', '', '', 40.14, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseHTTPAuth', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_UseHTTPAuth', 'checkbox', '', '', 40.15, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'HTTPAuthUsername', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_HTTPAuthUsername', 'text', '', '', 40.16, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'HTTPAuthPassword', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_HTTPAuthPassword', 'password', NULL, NULL, 40.17, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'HTTPAuthBypassIPs', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsAdmin', 'la_config_HTTPAuthBypassIPs', 'text', '', '', 40.18, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Smtp_Server', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_mailserver', 'text', NULL, NULL, 50.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Smtp_Port', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_mailport', 'text', NULL, NULL, 50.02, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Smtp_Authenticate', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_mailauthenticate', 'checkbox', NULL, NULL, 50.03, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Smtp_User', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_smtp_user', 'text', NULL, NULL, 50.04, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Smtp_Pass', NULL, 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_smtp_pass', 'text', NULL, NULL, 50.05, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Smtp_DefaultHeaders', 'X-Mailer: In-Portal', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_prompt_smtpheaders', 'textarea', NULL, 'COLS=40 ROWS=5', 50.06, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MailFunctionHeaderSeparator', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_MailFunctionHeaderSeparator', 'radio', NULL, '1=la_Linux||2=la_Windows', 50.07, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MailingListQueuePerStep', '10', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_MailingListQueuePerStep', 'text', NULL, NULL, 50.08, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MailingListSendPerStep', '10', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_MailingListSendPerStep', 'text', NULL, NULL, 50.09, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'DefaultEmailRecipients', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsMailling', 'la_config_DefaultEmailRecipients', 'text', NULL, NULL, 50.10, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseOutputCompression', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_UseOutputCompression', 'checkbox', '', '', 60.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'OutputCompressionLevel', '7', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_OutputCompressionLevel', 'text', '', '', 60.02, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseTemplateCompression', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_UseTemplateCompression', 'checkbox', '', '', 60.03, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'TrimRequiredFields', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_TrimRequiredFields', 'checkbox', '', '', 60.04, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'RunScheduledTasksFromCron', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_UseCronForRegularEvent', 'checkbox', NULL, NULL, 60.05, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UseChangeLog', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_UseChangeLog', 'checkbox', '', '', 60.06, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Backup_Path', '/home/alex/web/in-portal.rc/system/backupdata', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_config_backup_path', 'text', '', '', 60.07, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SystemTagCache', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_prompt_syscache_enable', 'checkbox', NULL, NULL, 60.08, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SocketBlockingMode', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsSystem', 'la_prompt_socket_blocking_mode', 'checkbox', NULL, NULL, 60.09, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'CSVExportDelimiter', '1', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportDelimiter', 'select', NULL, '0=la_opt_Tab||1=la_opt_Comma||2=la_opt_Semicolon||3=la_opt_Space||4=la_opt_Colon', 70.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'CSVExportEnclosure', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportEnclosure', 'radio', NULL, '0=la_Doublequotes||1=la_Quotes', 70.02, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'CSVExportSeparator', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportSeparator', 'radio', NULL, '0=la_Linux||1=la_Windows', 70.03, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'CSVExportEncoding', '0', 'In-Portal', 'in-portal:configure_advanced', 'la_section_SettingsCSVExport', 'la_config_CSVExportEncoding', 'radio', NULL, '0=la_Unicode||1=la_Regular', 70.04, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'YahooApplicationId', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_Settings3rdPartyAPI', 'la_config_YahooApplicationId', 'text', NULL, NULL, 80.01, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'l_GoogleMapsAPIKey', '', 'In-Portal', 'in-portal:configure_advanced', 'la_section_Settings3rdPartyAPI', 'la_fld_LinkGoogleMapsAPIKey', 'text', NULL, NULL, 80.02, 0, 1, NULL); # Section "in-portal:configure_users": -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_Allow_New', '3', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_allow_new', 'radio', '', '1=la_opt_UserInstantRegistration||2=la_opt_UserNotAllowedRegistration||3=la_opt_UserUponApprovalRegistration||4=la_opt_UserEmailActivation', 10.01, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'AdvancedUserManagement', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_prompt_AdvancedUserManagement', 'checkbox', NULL, NULL, 10.011, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'RegistrationUsernameRequired', '1', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_RegistrationUsernameRequired', 'checkbox', NULL, NULL, 10.02, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'RegistrationCaptcha', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_registration_captcha', 'checkbox', NULL, NULL, 10.025, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Min_UserName', '3', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_text_min_username', 'text', '', 'style="width: 50px;"', 10.03, 1, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'MaxUserName', '', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_text_min_username', 'text', '', 'style="width: 50px;"', 10.03, 2, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Min_Password', '5', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_text_min_password', 'text', '', '', 10.04, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'Users_AllowReset', '180', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_prompt_allow_reset', 'text', NULL, NULL, 10.05, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UserEmailActivationTimeout', '', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_UserEmailActivationTimeout', 'text', NULL, NULL, 10.051, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_Password_Auto', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_password_auto', 'checkbox', '', '', 10.06, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_MembershipExpirationReminder', '10', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_MembershipExpirationReminder', 'text', NULL, '', 10.07, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_NewGroup', '13', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_new_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM PortalGroup WHERE Enabled=1 AND Personal=0', 10.08, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_LoggedInGroup', '15', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_assign_all_to', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM PortalGroup WHERE Enabled=1 AND Personal=0', 10.09, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_GuestGroup', '14', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_guest_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM PortalGroup WHERE Enabled=1 AND Personal=0', 10.1, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_SubscriberGroup', '12', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_subscriber_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM PortalGroup WHERE Enabled=1 AND Personal=0', 10.11, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_AdminGroup', '11', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_admin_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM PortalGroup WHERE Enabled=1 AND Personal=0', 10.12, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'User_Default_Registration_Country', '', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_DefaultRegistrationCountry', 'select', NULL, '=+||SELECT l%3$s_Name AS OptionName, CountryStateId AS OptionValue FROM CountryStates WHERE Type = 1 ORDER BY OptionName', 10.13, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'AllowSelectGroupOnFront', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_AllowSelectGroupOnFront', 'checkbox', NULL, NULL, 10.14, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'DefaultSettingsUserId', '-1', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_prompt_DefaultUserId', 'text', NULL, NULL, 10.15, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'u_MaxImageCount', '5', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_MaxImageCount', 'text', '', '', 30.01, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'u_ThumbnailImageWidth', '120', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_ThumbnailImageWidth', 'text', '', '', 30.02, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'u_ThumbnailImageHeight', '120', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_ThumbnailImageHeight', 'text', '', '', 30.03, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'u_FullImageWidth', '450', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_FullImageWidth', 'text', '', '', 30.04, 0, 0, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'u_FullImageHeight', '450', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_FullImageHeight', 'text', '', '', 30.05, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_Allow_New', '3', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_allow_new', 'radio', '', '1=la_opt_UserInstantRegistration||2=la_opt_UserNotAllowedRegistration||3=la_opt_UserUponApprovalRegistration||4=la_opt_UserEmailActivation', 10.01, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'AdvancedUserManagement', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_prompt_AdvancedUserManagement', 'checkbox', NULL, NULL, 10.011, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'RegistrationUsernameRequired', '1', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_RegistrationUsernameRequired', 'checkbox', NULL, NULL, 10.02, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'RegistrationCaptcha', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_registration_captcha', 'checkbox', NULL, NULL, 10.025, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Min_UserName', '3', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_text_min_username', 'text', '', 'style="width: 50px;"', 10.03, 1, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'MaxUserName', '', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_text_min_username', 'text', '', 'style="width: 50px;"', 10.03, 2, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Min_Password', '5', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_text_min_password', 'text', '', '', 10.04, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'Users_AllowReset', '180', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_prompt_allow_reset', 'text', NULL, NULL, 10.05, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'UserEmailActivationTimeout', '', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_UserEmailActivationTimeout', 'text', NULL, NULL, 10.051, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_Password_Auto', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_password_auto', 'checkbox', '', '', 10.06, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_MembershipExpirationReminder', '10', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_MembershipExpirationReminder', 'text', NULL, '', 10.07, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_NewGroup', '13', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_new_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM UserGroups WHERE Enabled=1 AND Personal=0', 10.08, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_LoggedInGroup', '15', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_assign_all_to', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM UserGroups WHERE Enabled=1 AND Personal=0', 10.09, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_GuestGroup', '14', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_guest_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM UserGroups WHERE Enabled=1 AND Personal=0', 10.1, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_SubscriberGroup', '12', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_subscriber_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM UserGroups WHERE Enabled=1 AND Personal=0', 10.11, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_AdminGroup', '11', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_users_admin_group', 'select', NULL, '0=lu_none||SELECT GroupId as OptionValue, Name as OptionName FROM UserGroups WHERE Enabled=1 AND Personal=0', 10.12, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'User_Default_Registration_Country', '', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_DefaultRegistrationCountry', 'select', NULL, '=+||SELECT l%3$s_Name AS OptionName, CountryStateId AS OptionValue FROM CountryStates WHERE Type = 1 ORDER BY OptionName', 10.13, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'AllowSelectGroupOnFront', '0', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_config_AllowSelectGroupOnFront', 'checkbox', NULL, NULL, 10.14, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'DefaultSettingsUserId', '-1', 'In-Portal:Users', 'in-portal:configure_users', 'la_title_General', 'la_prompt_DefaultUserId', 'text', NULL, NULL, 10.15, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'u_MaxImageCount', '5', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_MaxImageCount', 'text', '', '', 30.01, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'u_ThumbnailImageWidth', '120', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_ThumbnailImageWidth', 'text', '', '', 30.02, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'u_ThumbnailImageHeight', '120', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_ThumbnailImageHeight', 'text', '', '', 30.03, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'u_FullImageWidth', '450', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_FullImageWidth', 'text', '', '', 30.04, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'u_FullImageHeight', '450', 'In-Portal:Users', 'in-portal:configure_users', 'la_section_ImageSettings', 'la_config_FullImageHeight', 'text', '', '', 30.05, 0, 0, NULL); # Section "in-portal:configuration_search": -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SearchRel_Increase_category', '30', 'In-Portal', 'in-portal:configuration_search', 'la_config_DefaultIncreaseImportance', 'la_text_increase_importance', 'text', NULL, NULL, 0, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SearchRel_Keyword_category', '90', 'In-Portal', 'in-portal:configuration_search', 'la_config_SearchRel_DefaultKeyword', 'la_text_keyword', 'text', NULL, NULL, 0, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SearchRel_Pop_category', '5', 'In-Portal', 'in-portal:configuration_search', 'la_config_DefaultPop', 'la_text_popularity', 'text', NULL, NULL, 0, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'SearchRel_Rating_category', '5', 'In-Portal', 'in-portal:configuration_search', 'la_config_DefaultRating', 'la_prompt_Rating', 'text', NULL, NULL, 0, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SearchRel_Increase_category', '30', 'In-Portal', 'in-portal:configuration_search', 'la_config_DefaultIncreaseImportance', 'la_text_increase_importance', 'text', NULL, NULL, 0, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SearchRel_Keyword_category', '90', 'In-Portal', 'in-portal:configuration_search', 'la_config_SearchRel_DefaultKeyword', 'la_text_keyword', 'text', NULL, NULL, 0, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SearchRel_Pop_category', '5', 'In-Portal', 'in-portal:configuration_search', 'la_config_DefaultPop', 'la_text_popularity', 'text', NULL, NULL, 0, 0, 1, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'SearchRel_Rating_category', '5', 'In-Portal', 'in-portal:configuration_search', 'la_config_DefaultRating', 'la_prompt_Rating', 'text', NULL, NULL, 0, 0, 1, NULL); -INSERT INTO ConfigurationValues VALUES(DEFAULT, 'CategoriesRebuildSerial', '0', 'In-Portal', '', '', '', '', NULL, NULL, 0, 0, 0, NULL); +INSERT INTO SystemSettings VALUES(DEFAULT, 'CategoriesRebuildSerial', '0', 'In-Portal', '', '', '', '', NULL, NULL, 0, 0, 0, NULL); -INSERT INTO ItemTypes VALUES (1, 'In-Portal', 'c', 'Category', 'Name', 'CreatedById', NULL, NULL, 'la_ItemTab_Categories', 1, 'admin/category/addcategory.php', 'clsCategory', 'Category'); -INSERT INTO ItemTypes VALUES (6, 'In-Portal', 'u', 'PortalUser', 'Username', 'PortalUserId', NULL, NULL, '', 0, '', 'clsPortalUser', 'User'); +INSERT INTO ItemTypes VALUES (1, 'In-Portal', 'c', 'Categories', 'Name', 'CreatedById', NULL, NULL, 'la_ItemTab_Categories', 1, 'admin/category/addcategory.php', 'clsCategory', 'Category'); +INSERT INTO ItemTypes VALUES (6, 'In-Portal', 'u', 'Users', 'Username', 'PortalUserId', NULL, NULL, '', 0, '', 'clsPortalUser', 'User'); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD', NULL, 1, 0, 'Core', 'Add User', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD', NULL, 1, 1, 'Core', 'Add User', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.APPROVE', NULL, 1, 0, 'Core', 'Approve User', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.APPROVE', NULL, 1, 1, 'Core', 'Approve User', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.VALIDATE', NULL, 1, 0, 'Core', 'Validate User', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.VALIDATE', NULL, 1, 1, 'Core', 'Validate User', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.DENY', NULL, 1, 0, 'Core', 'Deny User', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.DENY', NULL, 1, 1, 'Core', 'Deny User', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD.PENDING', NULL, 1, 0, 'Core', 'Add Pending User', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD.PENDING', NULL, 1, 1, 'Core', 'Add Pending User', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD', NULL, 1, 0, 'Core', 'Add Category', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD.PENDING', NULL, 1, 0, 'Core', 'Add Pending Category', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD.PENDING', NULL, 1, 1, 'Core', 'Add Pending Category', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD', NULL, 1, 1, 'Core', 'Add Category', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.APPROVE', NULL, 1, 0, 'Core', 'Approve Category', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.DENY', NULL, 1, 0, 'Core', 'Deny Category', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUBSCRIBE', NULL, 1, 0, 'Core', 'User subscribed', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUBSCRIBE', NULL, 1, 1, 'Core', 'User subscribed', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.UNSUBSCRIBE', NULL, 1, 0, 'Core', 'User unsubscribed', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.UNSUBSCRIBE', NULL, 1, 1, 'Core', 'User unsubscribed', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUGGEST', NULL, 1, 0, 'Core', 'Suggest to a friend', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUGGEST', NULL, 1, 1, 'Core', 'Suggest to a friend', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.PSWDC', NULL, 1, 0, 'Core', 'Password Confirmation', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRED', NULL, 1, 0, 'Core', 'Membership expired', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRED', NULL, 1, 0, 'Core', 'Membership expired', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRATION.NOTICE', NULL, 1, 0, 'Core', 'Membership expiration notice', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRATION.NOTICE', NULL, 1, 0, 'Core', 'Membership expiration notice', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'COMMON.FOOTER', NULL, 1, 0, 'Core', 'Common Footer Template', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMITTED', NULL, 1, 0, 'Core', 'This e-mail is sent to a user after filling in the Contact Us form', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMITTED', NULL, 1, 0, 'Core', 'This e-mail is sent to a user after filling in the Contact Us form', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMISSION.REPLY.TO.USER', NULL, 1, 0, 'Core', 'Admin Reply to User Form Submission', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMISSION.REPLY.FROM.USER', NULL, 1, 0, 'Core', 'User Replied to It\'s Form Submission', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMISSION.REPLY.FROM.USER.BOUNCED', NULL, 1, 0, 'Core', 'Form Submission Admin Reply Delivery Failure', 1, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.NEW.PASSWORD', NULL, 1, 0, 'Core', 'Sends new password to an existing user', 0, 1, 0); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD.BYADMIN', NULL, 1, 0, 'Core', 'Sends password to a new user', 0, 1, 0); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'ROOT.RESET.PASSWORD', NULL, 1, 0, 'Core', 'Root Reset Password', 1, 1, 0); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.EMAIL.CHANGE.VERIFY', NULL, 1, 0, 'Core', 'Changed E-mail Verification', 0, 1, 1); -INSERT INTO Events (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.EMAIL.CHANGE.UNDO', NULL, 1, 0, 'Core', 'Changed E-mail Rollback', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD', NULL, 1, 0, 'Core', 'Add User', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD', NULL, 1, 1, 'Core', 'Add User', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.APPROVE', NULL, 1, 0, 'Core', 'Approve User', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.APPROVE', NULL, 1, 1, 'Core', 'Approve User', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.VALIDATE', NULL, 1, 0, 'Core', 'Validate User', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.VALIDATE', NULL, 1, 1, 'Core', 'Validate User', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.DENY', NULL, 1, 0, 'Core', 'Deny User', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.DENY', NULL, 1, 1, 'Core', 'Deny User', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD.PENDING', NULL, 1, 0, 'Core', 'Add Pending User', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD.PENDING', NULL, 1, 1, 'Core', 'Add Pending User', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD', NULL, 1, 0, 'Core', 'Add Category', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD.PENDING', NULL, 1, 0, 'Core', 'Add Pending Category', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD.PENDING', NULL, 1, 1, 'Core', 'Add Pending Category', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.ADD', NULL, 1, 1, 'Core', 'Add Category', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.APPROVE', NULL, 1, 0, 'Core', 'Approve Category', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'CATEGORY.DENY', NULL, 1, 0, 'Core', 'Deny Category', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUBSCRIBE', NULL, 1, 0, 'Core', 'User subscribed', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUBSCRIBE', NULL, 1, 1, 'Core', 'User subscribed', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.UNSUBSCRIBE', NULL, 1, 0, 'Core', 'User unsubscribed', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.UNSUBSCRIBE', NULL, 1, 1, 'Core', 'User unsubscribed', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUGGEST', NULL, 1, 0, 'Core', 'Suggest to a friend', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.SUGGEST', NULL, 1, 1, 'Core', 'Suggest to a friend', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.PSWDC', NULL, 1, 0, 'Core', 'Password Confirmation', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRED', NULL, 1, 0, 'Core', 'Membership expired', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRED', NULL, 1, 0, 'Core', 'Membership expired', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRATION.NOTICE', NULL, 1, 0, 'Core', 'Membership expiration notice', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.MEMBERSHIP.EXPIRATION.NOTICE', NULL, 1, 0, 'Core', 'Membership expiration notice', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'COMMON.FOOTER', NULL, 1, 0, 'Core', 'Common Footer Template', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMITTED', NULL, 1, 0, 'Core', 'This e-mail is sent to a user after filling in the Contact Us form', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMITTED', NULL, 1, 0, 'Core', 'This e-mail is sent to a user after filling in the Contact Us form', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMISSION.REPLY.TO.USER', NULL, 1, 0, 'Core', 'Admin Reply to User Form Submission', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMISSION.REPLY.FROM.USER', NULL, 1, 0, 'Core', 'User Replied to It\'s Form Submission', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'FORM.SUBMISSION.REPLY.FROM.USER.BOUNCED', NULL, 1, 0, 'Core', 'Form Submission Admin Reply Delivery Failure', 1, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.NEW.PASSWORD', NULL, 1, 0, 'Core', 'Sends new password to an existing user', 0, 1, 0); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.ADD.BYADMIN', NULL, 1, 0, 'Core', 'Sends password to a new user', 0, 1, 0); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'ROOT.RESET.PASSWORD', NULL, 1, 0, 'Core', 'Root Reset Password', 1, 1, 0); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.EMAIL.CHANGE.VERIFY', NULL, 1, 0, 'Core', 'Changed E-mail Verification', 0, 1, 1); +INSERT INTO EmailEvents (EventId, Event, ReplacementTags, Enabled, FrontEndOnly, Module, Description, Type, AllowChangingSender, AllowChangingRecipient) VALUES(DEFAULT, 'USER.EMAIL.CHANGE.UNDO', NULL, 1, 0, 'Core', 'Changed E-mail Rollback', 0, 1, 1); INSERT INTO IdGenerator VALUES ('100'); -INSERT INTO PortalGroup VALUES(15, 'Everyone', 'Everyone', 0, 1, 0, 1, 0, NULL); -INSERT INTO PortalGroup VALUES(13, 'Member', '', 1054738682, 0, 0, 1, 1, NULL); -INSERT INTO PortalGroup VALUES(12, 'Subscribers', '', 1054738670, 0, 0, 1, 0, NULL); -INSERT INTO PortalGroup VALUES(14, 'Guest', 'Guest User', 0, 1, 0, 1, 0, NULL); -INSERT INTO PortalGroup VALUES(11, 'admin', NULL, 1054738405, 0, 0, 1, 0, NULL); +INSERT INTO UserGroups VALUES(15, 'Everyone', 'Everyone', 0, 1, 0, 1, 0, NULL); +INSERT INTO UserGroups VALUES(13, 'Member', '', 1054738682, 0, 0, 1, 1, NULL); +INSERT INTO UserGroups VALUES(12, 'Subscribers', '', 1054738670, 0, 0, 1, 0, NULL); +INSERT INTO UserGroups VALUES(14, 'Guest', 'Guest User', 0, 1, 0, 1, 0, NULL); +INSERT INTO UserGroups VALUES(11, 'admin', NULL, 1054738405, 0, 0, 1, 0, NULL); INSERT INTO CountryStates (CountryStateId, Type, StateCountryId, IsoCode, ShortIsoCode) VALUES (1, 1, NULL, 'AFG', 'AF'), @@ -494,26 +494,26 @@ (307, 2, 225, 'AK', NULL), (306, 2, 225, 'AL', NULL); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.VIEW', 'la_PermName_Category.View_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.ADD', 'la_PermName_Category.Add_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.DELETE', 'la_PermName_Category.Delete_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.ADD.PENDING', 'la_PermName_Category.AddPending_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.MODIFY', 'la_PermName_Category.Modify_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.REVISION.ADD', 'la_PermName_Category.Revision.Add_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.REVISION.ADD.PENDING', 'la_PermName_Category.Revision.Add.Pending_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.REVISION.MODERATE', 'la_PermName_Category.Revision.Moderate_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.REVISION.HISTORY.VIEW', 'la_PermName_Category.Revision.History.View_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'CATEGORY.REVISION.HISTORY.RESTORE', 'la_PermName_Category.Revision.History.Restore_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'ADMIN', 'la_PermName_Admin_desc', 'Admin', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'LOGIN', 'la_PermName_Login_desc', 'Front', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'DEBUG.ITEM', 'la_PermName_Debug.Item_desc', 'Admin', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'DEBUG.LIST', 'la_PermName_Debug.List_desc', 'Admin', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'DEBUG.INFO', 'la_PermName_Debug.Info_desc', 'Admin', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'PROFILE.MODIFY', 'la_PermName_Profile.Modify_desc', 'Admin', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'SHOWLANG', 'la_PermName_ShowLang_desc', 'Admin', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'FAVORITES', 'la_PermName_favorites_desc', 'In-Portal', 1); -INSERT INTO PermissionConfig VALUES (DEFAULT, 'SYSTEM_ACCESS.READONLY', 'la_PermName_SystemAccess.ReadOnly_desc', 'Admin', 1); -INSERT INTO PermCache VALUES (DEFAULT, 0, 1, '11,12,13,14,15'); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.VIEW', 'la_PermName_Category.View_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.ADD', 'la_PermName_Category.Add_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.DELETE', 'la_PermName_Category.Delete_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.ADD.PENDING', 'la_PermName_Category.AddPending_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.MODIFY', 'la_PermName_Category.Modify_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.REVISION.ADD', 'la_PermName_Category.Revision.Add_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.REVISION.ADD.PENDING', 'la_PermName_Category.Revision.Add.Pending_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.REVISION.MODERATE', 'la_PermName_Category.Revision.Moderate_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.REVISION.HISTORY.VIEW', 'la_PermName_Category.Revision.History.View_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'CATEGORY.REVISION.HISTORY.RESTORE', 'la_PermName_Category.Revision.History.Restore_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'ADMIN', 'la_PermName_Admin_desc', 'Admin', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'LOGIN', 'la_PermName_Login_desc', 'Front', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'DEBUG.ITEM', 'la_PermName_Debug.Item_desc', 'Admin', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'DEBUG.LIST', 'la_PermName_Debug.List_desc', 'Admin', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'DEBUG.INFO', 'la_PermName_Debug.Info_desc', 'Admin', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'PROFILE.MODIFY', 'la_PermName_Profile.Modify_desc', 'Admin', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'SHOWLANG', 'la_PermName_ShowLang_desc', 'Admin', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'FAVORITES', 'la_PermName_favorites_desc', 'In-Portal', 1); +INSERT INTO CategoryPermissionsConfig VALUES (DEFAULT, 'SYSTEM_ACCESS.READONLY', 'la_PermName_SystemAccess.ReadOnly_desc', 'Admin', 1); +INSERT INTO CategoryPermissionsCache VALUES (DEFAULT, 0, 1, '11,12,13,14,15'); INSERT INTO Permissions VALUES (DEFAULT, 'LOGIN', 13, 1, 1, 0); @@ -712,7 +712,7 @@ INSERT INTO Permissions VALUES (DEFAULT, 'in-portal:permission_types.edit', 11, 1, 1, 0); INSERT INTO Permissions VALUES (DEFAULT, 'in-portal:permission_types.delete', 11, 1, 1, 0); -INSERT INTO Skins VALUES (DEFAULT, 'Default', '/* General elements */\r\n\r\nhtml {\r\n height: 100%;\r\n}\r\n\r\nbody {\r\n font-family: verdana,arial,helvetica,sans-serif;\r\n color: #000000;\r\n overflow-x: auto; overflow-y: auto;\r\n margin: 0px 0px 0px 0px;\r\n text-decoration: none;\r\n}\r\n\r\nbody, td {\r\n /* fix for Firefox, when font-size was not inherited in table cells */\r\n font-size: 9pt;\r\n}\r\n\r\na {\r\n color: #006699;\r\n text-decoration: none;\r\n}\r\n\r\na:hover {\r\n color: #009ff0;\r\n text-decoration: none;\r\n}\r\n\r\nform {\r\n display: inline;\r\n}\r\n\r\nimg { border: 0px; }\r\n\r\nbody.height-100 {\r\n height: 100%;\r\n}\r\n\r\nbody.regular-body {\r\n margin: 0px 10px 5px 10px;\r\n color: #000000;\r\n background-color: @@SectionBgColor@@;\r\n}\r\n\r\nbody.edit-popup {\r\n margin: 0px 0px 0px 0px;\r\n}\r\n\r\ntable.collapsed {\r\n border-collapse: collapse;\r\n}\r\n\r\n.bordered, table.bordered, .bordered-no-bottom {\r\n border: 1px solid #000000 !important;\r\n border-top-width: 0px;\r\n border-collapse: collapse;\r\n}\r\n\r\n.bordered-no-bottom {\r\n border-top-width: 1px;\r\n border-bottom: none;\r\n}\r\n\r\n.login-table td {\r\n padding: 1px;\r\n}\r\n\r\n.disabled {\r\n background-color: #ebebeb;\r\n}\r\n\r\n/* Head frame */\r\ntable.head-table {\r\n background: url(''@@base_url@@/core/admin_templates/img/top_frame/right_background.png'') top right @@HeadBgColor@@ no-repeat;\r\n}\r\n\r\n.head-table tr td, .head-table tr td a {\r\n color: @@HeadColor@@\r\n}\r\n\r\ndiv#extra_toolbar td.button-active {\r\n background: url(''@@base_url@@/core/admin_templates/img/top_frame/toolbar_button_background.gif'') bottom left repeat-x;\r\n height: 22px;\r\n}\r\n\r\ndiv#extra_toolbar td.button-active a {\r\n color: black;\r\n text-decoration: none;\r\n}\r\n\r\ntd.kx-block-header, .head-table tr td.kx-block-header{\r\n color: @@HeadBarColor@@;\r\n background: url(''@@base_url@@/core/admin_templates/img/top_frame/toolbar_background.gif'') repeat-x top left;\r\n /*background-color: @@HeadBarBgColor@@;*/\r\n padding-left: 7px;\r\n padding-right: 7px;\r\n}\r\n\r\na.kx-header-link {\r\n text-decoration: underline;\r\n font-weight: bold;\r\n color: #0080C8;\r\n}\r\n\r\na.kx-header-link:hover {\r\n color: #FFCB05;\r\n text-decoration: none;\r\n}\r\n\r\n.kx-secondary-foreground {\r\n color: #FFFFFF;\r\n /*background-color: @@HeadBarBgColor@@;*/\r\n}\r\n\r\n.kx-login-button {\r\n background-color: #2D79D6;\r\n color: #FFFFFF;\r\n}\r\n\r\n/* General form button (yellow) */\r\n.button {\r\n font-size: 12px;\r\n font-weight: normal;\r\n color: #000000;\r\n background: url(''@@base_url@@/core/admin_templates/img/button_back.gif'') #f9eeae repeat-x;\r\n text-decoration: none;\r\n}\r\n\r\n/* Disabled (grayed-out) form button */\r\n.button-disabled {\r\n font-size: 12px;\r\n font-weight: normal;\r\n color: #676767;\r\n background: url(''@@base_url@@/core/admin_templates/img/button_back_disabled.gif'') #f9eeae repeat-x;\r\n text-decoration: none;\r\n}\r\n\r\n/* Tabs bar */\r\n\r\n.tab, .tab-active {\r\n background-color: #F0F1EB;\r\n padding: 3px 7px 2px 7px;\r\n border-top: 1px solid black;\r\n border-left: 1px solid black;\r\n border-right: 1px solid black;\r\n margin-left: 3px !important;\r\n white-space: nowrap;\r\n}\r\n\r\n.tab-active {\r\n background-color: #4487D9;\r\n}\r\n\r\n.tab a {\r\n color: #4487D9;\r\n font-weight: bold;\r\n}\r\n\r\n.tab-active a {\r\n color: #FFFFFF;\r\n font-weight: bold;\r\n}\r\n\r\na.scroll-left, a.scroll-right {\r\n cursor: pointer;\r\n display: block;\r\n float: left;\r\n height: 18px;\r\n margin: 0px 1px;\r\n width: 18px;\r\n}\r\n\r\na.scroll-left {\r\n background: transparent url(''@@base_url@@/core/admin_templates/img/tabs/left.png'') no-repeat scroll 0 0;\r\n}\r\n\r\na.scroll-right {\r\n background: transparent url(''@@base_url@@/core/admin_templates/img/tabs/right.png'') no-repeat scroll 0 0;\r\n}\r\n\r\na.disabled {\r\n visibility: hidden !important;\r\n}\r\n\r\na.scroll-left:hover, a.scroll-right:hover {\r\n background-position: 0 -18px;\r\n}\r\n\r\ntd.scroll-right-container {\r\n width: 20px;\r\n}\r\n\r\ntd.scroll-right-container.disabled, td.scroll-right-container.disabled * {\r\n width: 0px;\r\n margin: 0px;\r\n}\r\n\r\ntd.scroll-right-container.disabled br {\r\n display: none;\r\n}\r\n\r\n/* Toolbar */\r\n\r\n.toolbar {\r\n font-size: 8pt;\r\n border: 1px solid #000000;\r\n border-width: 0px 1px 1px 1px;\r\n background-color: @@ToolbarBgColor@@;\r\n border-collapse: collapse;\r\n}\r\n\r\n.toolbar td {\r\n height: 100%;\r\n}\r\n\r\n.toolbar-button, .toolbar-button-disabled, .toolbar-button-over {\r\n float: left;\r\n text-align: center;\r\n font-size: 8pt;\r\n padding: 5px 5px 5px 5px;\r\n vertical-align: middle;\r\n color: #006F99;\r\n}\r\n\r\n.toolbar-button-over {\r\n color: #000;\r\n}\r\n\r\n.toolbar-button-disabled {\r\n color: #444;\r\n}\r\n\r\n/* Scrollable Grids */\r\n\r\n\r\n.layout-only-table td {\r\n border: none !important;\r\n}\r\n\r\n/* Main Grid class */\r\n.grid-scrollable {\r\n padding: 0px;\r\n border: 1px solid black !important;\r\n border-top: none !important;\r\n}\r\n\r\n/* Div generated by js, which contains all the scrollable grid elements, affects the style of scrollable area without data (if there are too few rows) */\r\n.grid-container {\r\n background-color: #fff;\r\n}\r\n\r\n.grid-container table {\r\n border-collapse: collapse;\r\n}\r\n\r\n/* Inner div generated in each data-cell */\r\n.grid-cell-div {\r\n overflow: hidden;\r\n height: auto;\r\n}\r\n\r\n/* Main row definition */\r\n.grid-data-row td, .grid-data-row-selected td, .grid-data-row-even-selected td, .grid-data-row-mouseover td, .table-color1, .table-color2, .grid-edit-table .edit-form-odd > td, .grid-edit-table .edit-form-even > td {\r\n font-weight: normal;\r\n color: @@OddColor@@;\r\n background-color: @@OddBgColor@@;\r\n padding: 3px 5px 3px 5px;\r\n overflow: hidden;\r\n border-right: 1px solid #c9c9c9;\r\n}\r\n.grid-data-row-even td, .table-color2, .grid-edit-table .edit-form-even > td {\r\n background-color: @@EvenBgColor@@;\r\n color: @@EvenColor@@;\r\n}\r\n.grid-data-row td a, .grid-data-row-selected td a, .grid-data-row-mouseover td a {\r\n text-decoration: underline;\r\n}\r\n\r\n/* mouse-over rows */\r\n.grid-data-row-mouseover td, table tr.grid-data-row[_row_highlighted] td {\r\n background: #FFFDF4;\r\n}\r\n\r\n/* Selected row, applies to both checkbox and data areas */\r\n.grid-data-row-selected td, table tr.grid-data-row[_row_selected] td {\r\n background: #FEF2D6;\r\n}\r\n\r\n.grid-data-row-even-selected td, .grid-data-row-even[_row_selected] td {\r\n background: #FFF7E0;\r\n}\r\n\r\n/* General header cell definition */\r\n.grid-header-row td {\r\n font-weight: bold;\r\n background-color: @@ColumnTitlesBgColor@@;\r\n text-decoration: none;\r\n padding: 3px 5px 3px 5px;\r\n color: @@ColumnTitlesColor@@;\r\n border-right: none;\r\n text-align: left;\r\n vertical-align: middle !important;\r\n white-space: nowrap;\r\n border-right: 1px solid #777;\r\n}\r\n\r\n/* Filters row */\r\ntr.grid-header-row-1 td {\r\n background-color: @@FiltersBgColor@@;\r\n border-bottom: 1px solid black;\r\n}\r\n\r\n/* Grid Filters */\r\ntable.range-filter {\r\n width: 100%;\r\n}\r\n\r\n.range-filter td {\r\n padding: 0px 0px 2px 2px !important;\r\n border: none !important;\r\n font-size: 8pt !important;\r\n font-weight: normal !important;\r\n text-align: left;\r\n color: #000000 !important;\r\n}\r\n\r\ninput.filter, select.filter, input.filter-active, select.filter-active {\r\n margin-bottom: 0px;\r\n border: 1px solid #aaa;\r\n}\r\n\r\ninput.filter-active {\r\n background-color: #FFFF00;\r\n}\r\n\r\nselect.filter-active {\r\n background-color: #FFFF00;\r\n}\r\n\r\ndiv.filter, div.filter-active {\r\n background-color: white;\r\n border: 1px solid #AAAAAA;\r\n color: black;\r\n font-weight: normal;\r\n padding: 3px;\r\n}\r\n\r\ndiv.filter-active {\r\n background-color: #FFFF00;\r\n}\r\n\r\ndiv.multioptions_filter {\r\n position: absolute;\r\n z-index: 100;\r\n color: black;\r\n background-color: white;\r\n border: 1px solid black;\r\n padding: 3px 5px;\r\n display: none;\r\n vertical-align: middle;\r\n}\r\n\r\n/* Column titles row */\r\ntr.grid-header-row-0 td {\r\n height: 25px;\r\n font-weight: bold;\r\n background-color: @@ColumnTitlesBgColor@@;\r\n color: @@ColumnTitlesColor@@;\r\n border-bottom: 1px solid black;\r\n}\r\n\r\ntr.grid-header-row-0 td a {\r\n color: @@ColumnTitlesColor@@;\r\n}\r\n\r\ntr.grid-header-row-0 td a:hover {\r\n color: #FFCC00;\r\n}\r\n\r\n\r\n.grid-footer-row td {\r\n background-color: #D7D7D7;\r\n font-weight: bold;\r\n border-right: 1px solid #C9C9C9;\r\n padding: 3px 5px 3px 5px;\r\n}\r\n\r\ntd.grid-header-last-cell, td.grid-data-last-cell, td.grid-footer-last-cell {\r\n border-right: none !important;\r\n}\r\n\r\ntd.grid-data-col-0, td.grid-data-col-0 div {\r\n text-align: center;\r\n vertical-align: middle !important;\r\n}\r\n\r\ntr.grid-header-row-1 td.grid-header-col-1 {\r\n text-align: center;\r\n vertical-align: middle !important;\r\n}\r\n\r\ntr.grid-header-row-1 td.grid-header-col-1 div {\r\n display: table-cell;\r\n vertical-align: middle;\r\n}\r\n\r\n.grid-status-bar {\r\n border: 1px solid black;\r\n border-top: none;\r\n padding: 0px;\r\n width: 100%;\r\n border-collapse: collapse;\r\n height: 30px;\r\n}\r\n\r\n.grid-status-bar td {\r\n background-color: @@TitleBarBgColor@@;\r\n color: @@TitleBarColor@@;\r\n font-size: 11pt;\r\n font-weight: normal;\r\n padding: 2px 8px 2px 8px;\r\n}\r\n\r\n/* /Scrollable Grids */\r\n\r\n\r\n/* Forms */\r\ntable.edit-form {\r\n border: none;\r\n border-top-width: 0px !important;\r\n border-collapse: collapse;\r\n width: 100%;\r\n}\r\n\r\n.edit-form-odd, .edit-form-even {\r\n padding: 0px;\r\n}\r\n\r\n.subsectiontitle {\r\n font-size: 10pt;\r\n font-weight: bold;\r\n background-color: #4A92CE;\r\n color: #fff;\r\n height: 25px;\r\n border-top: 1px solid black;\r\n vertical-align: middle;\r\n}\r\n\r\n/* remove top-border from first sub-section element */\r\ntable.edit-form .subsectiontitle:first-child, table.bordered .subsectiontitle:first-child {\r\n border-top-width: 0;\r\n}\r\n\r\n.subsectiontitle td {\r\n vertical-align: middle;\r\n /*padding: 3px 5px 3px 5px;*/\r\n padding: 1px 5px;\r\n}\r\n\r\n.label-cell {\r\n background: #DEE7F6 url(''@@base_url@@/core/admin_templates/img/bgr_input_name_line.gif'') no-repeat right bottom;\r\n font: 12px arial, sans-serif;\r\n padding: 4px 20px;\r\n width: 160px;\r\n}\r\n\r\n.control-mid {\r\n width: 13px;\r\n border-left: 1px solid #7A95C2;\r\n background: #fff url(''@@base_url@@/core/admin_templates/img/bgr_mid.gif'') repeat-x left bottom;\r\n}\r\n\r\n.control-cell {\r\n font: 11px arial, sans-serif;\r\n padding: 4px 10px 5px 5px;\r\n background: #fff url(''@@base_url@@/core/admin_templates/img/bgr_input_line.gif'') no-repeat left bottom;\r\n width: auto;\r\n vertical-align: middle;\r\n}\r\n\r\n.label-cell-filler {\r\n background: #DEE7F6 none;\r\n}\r\n.control-mid-filler {\r\n background: #fff none;\r\n border-left: 1px solid #7A95C2;\r\n}\r\n.control-cell-filler {\r\n background: #fff none;\r\n}\r\n\r\n.error {\r\n color: red;\r\n}\r\n.error-cell {\r\n color: red;\r\n}\r\n\r\n.field-required {\r\n color: red;\r\n}\r\n\r\n.warning-table {\r\n background-color: #F0F1EB;\r\n border: 1px solid #000000;\r\n border-collapse: collapse;\r\n border-top-width: 0px;\r\n}\r\n\r\n.form-notice, .form-warning {\r\n font-size: 11px;\r\n}\r\n\r\n.form-warning {\r\n color: red;\r\n}\r\n\r\n.form-notice {\r\n color: green;\r\n}\r\n\r\n.priority {\r\n color: red;\r\n padding-left: 1px;\r\n padding-right: 1px;\r\n font-size: 11px;\r\n}\r\n\r\n.small-statistics {\r\n font-size: 11px;\r\n color: #707070;\r\n}\r\n\r\n.req-note {\r\n font-style: italic;\r\n color: #333;\r\n}\r\n\r\n#scroll_container table.tableborder {\r\n border-collapse: separate\r\n}\r\n\r\n/* Uploader */\r\n.uploader-queue div.file {\r\n font-size: 11px;\r\n border: 1px solid #7F99C5;\r\n padding: 3px;\r\n background-color: #DEE7F6;\r\n margin-bottom: 2px;\r\n}\r\n\r\n.uploader-queue .left {\r\n float: left;\r\n vertical-align: top;\r\n}\r\n\r\n.uploader-queue .file-label {\r\n margin-left: 5px;\r\n}\r\n\r\n.uploader-queue .preview .delete-checkbox {\r\n margin-top: -3px;\r\n}\r\n\r\n.uploader-queue .progress-container {\r\n margin: 2px 5px 0px 5px;\r\n}\r\n\r\n.uploader-queue .progress-empty {\r\n width: 150px;\r\n height: 9px;\r\n border: 1px solid black;\r\n background: url(''@@base_url@@/core/admin_templates/img/progress_left.gif'') repeat-x;\r\n}\r\n\r\n.uploader-queue .progress-full {\r\n height: 9px;\r\n background: url(''@@base_url@@/core/admin_templates/img/progress_done.gif'');\r\n}\r\n\r\n.uploader-queue .thumbnail {\r\n /*margin-bottom: 2px;*/\r\n border: 1px solid black;\r\n background-color: grey;\r\n}\r\n\r\n/* To be sorted */\r\nspan#category_path, span#category_path a {\r\n color: #FFFFFF;\r\n}\r\n\r\nspan#category_path a {\r\n text-decoration: underline;\r\n}\r\n\r\n/* Section title, right to the big icon */\r\n.admintitle {\r\n font-size: 16pt;\r\n font-weight: bold;\r\n color: @@SectionColor@@;\r\n text-decoration: none;\r\n}\r\n\r\n/* Left side of bluebar */\r\n.header_left_bg {\r\n background-color: @@TitleBarBgColor@@;\r\n background-image: none;\r\n padding-left: 5px;\r\n}\r\n\r\n/* Right side of bluebar */\r\n.tablenav, tablenav a {\r\n font-size: 11pt;\r\n font-weight: bold;\r\n color: @@TitleBarColor@@;\r\n\r\n text-decoration: none;\r\n background-color: @@TitleBarBgColor@@;\r\n background-image: none;\r\n}\r\n\r\n/* Section title in the bluebar * -- why ''link''? :S */\r\n.tablenav_link {\r\n font-size: 11pt;\r\n font-weight: bold;\r\n color: @@TitleBarColor@@;\r\n text-decoration: none;\r\n}\r\n\r\n/* Active page in top and bottom bluebars pagination */\r\n.current_page {\r\n font-size: 10pt;\r\n font-weight: bold;\r\n background-color: #fff;\r\n color: #2D79D6;\r\n padding: 3px 2px 3px 3px;\r\n}\r\n\r\n/* Other pages and arrows in pagination on blue */\r\n.nav_url {\r\n font-size: 10pt;\r\n font-weight: bold;\r\n color: #fff;\r\n padding: 3px 2px 3px 3px;\r\n}\r\n\r\n/* Tree */\r\n.tree-body {\r\n background-color: @@TreeBgColor@@;\r\n height: 100%\r\n}\r\n\r\n.tree_head.td, .tree_head, .tree_head:hover {\r\n font-weight: bold;\r\n font-size: 10px;\r\n color: #FFFFFF;\r\n font-family: Verdana, Arial;\r\n text-decoration: none;\r\n}\r\n\r\n.tree {\r\n padding: 0px;\r\n border: none;\r\n border-collapse: collapse;\r\n}\r\n\r\n.tree tr td {\r\n padding: 0px;\r\n margin: 0px;\r\n font-family: helvetica, arial, verdana,;\r\n font-size: 11px;\r\n white-space: nowrap;\r\n}\r\n\r\n.tree tr td a {\r\n font-size: 11px;\r\n color: @@TreeColor@@;\r\n font-family: Helvetica, Arial, Verdana;\r\n text-decoration: none;\r\n padding: 2px;\r\n}\r\n\r\n.tree tr td a:hover, .tree tr td a.debug-only-item:hover {\r\n color: @@TreeHoverColor@@;\r\n}\r\n\r\n.tree tr.highlighted td a, .tree tr.highlighted td a.debug-only-item {\r\n color: @@TreeHighColor@@;\r\n background-color: @@TreeHighBgColor@@;\r\n}\r\n\r\n.tree tr.highlighted td a:hover {\r\n color: @@TreeHighHoverColor@@;\r\n}\r\n\r\n.tree tr td a.debug-only-item {\r\n color: grey;\r\n}\r\n\r\n/* Ajax Dropdown */\r\n.suggest-box {\r\n border: 1px solid #999;\r\n background-color: #fff;\r\n}\r\n\r\n.suggest-item, .suggest-item-over {\r\n padding: 1px 2px 0px 2px;\r\n font-family: arial,verdana;\r\n font-size: 12px;\r\n}\r\n\r\n.suggest-item-over {\r\n background-color: #3366CC;\r\n color: #fff;\r\n}\r\n\r\n/* Dashboard Summary Boxes */\r\n.summary-box {\r\n border: 1px solid black;\r\n margin-bottom: 4px;\r\n}\r\n\r\n.summary-box .title {\r\n color: white;\r\n font-weight: bold;\r\n padding: 6px 5px;\r\n vertical-align: middle;\r\n background-color: #4A92CE;\r\n border-bottom: 1px solid black;\r\n}\r\n\r\n.summary-box .content {\r\n padding: 4px;\r\n background-color: #F6F6F6;\r\n}\r\n\r\n.summary-box .group {\r\n border-bottom: 1px solid black;\r\n margin-bottom: 10px;\r\n padding: 0 0 10px 10px;\r\n}\r\n\r\n.summary-box .group.last {\r\n border-width: 0px;\r\n margin-bottom: 0;\r\n padding-bottom: 5px;\r\n}\r\n\r\n.summary-box h4 {\r\n margin: 0;\r\n padding: 0 0 3px 0;\r\n font-size: 11px;\r\n font-weight: bold;\r\n}\r\n\r\n.summary-box .hint {\r\n font-size: 10px;\r\n color: grey;\r\n margin-bottom: 3px;\r\n}\r\n\r\n.summary-box .hint .cache-key {\r\n margin-bottom: 7px;\r\n margin-left: 3px;\r\n}\r\n\r\n.summary-box ul {\r\n margin-top: 5px;\r\n margin-bottom: 3px;\r\n padding-left: 30px;\r\n}\r\n\r\n.summary-box li {\r\n padding-bottom: 4px;\r\n}', 'in-portal_logo_img.jpg', 'in-portal_logo_img2.jpg', 'in-portal_logo_login.gif', 'a:22:{s:11:"HeadBgColor";a:2:{s:11:"Description";s:27:"Head frame background color";s:5:"Value";s:7:"#007BF4";}s:9:"HeadColor";a:2:{s:11:"Description";s:21:"Head frame text color";s:5:"Value";s:7:"#FFFFFF";}s:14:"SectionBgColor";a:2:{s:11:"Description";s:28:"Section bar background color";s:5:"Value";s:7:"#FFFFFF";}s:12:"SectionColor";a:2:{s:11:"Description";s:22:"Section bar text color";s:5:"Value";s:7:"#2D79D6";}s:12:"HeadBarColor";a:1:{s:5:"Value";s:7:"#000000";}s:14:"HeadBarBgColor";a:1:{s:5:"Value";s:7:"#1961B8";}s:13:"TitleBarColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:15:"TitleBarBgColor";a:1:{s:5:"Value";s:7:"#2D79D6";}s:14:"ToolbarBgColor";a:1:{s:5:"Value";s:7:"#F0F1EB";}s:14:"FiltersBgColor";a:1:{s:5:"Value";s:7:"#D7D7D7";}s:17:"ColumnTitlesColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:19:"ColumnTitlesBgColor";a:1:{s:5:"Value";s:7:"#999999";}s:8:"OddColor";a:1:{s:5:"Value";s:7:"#000000";}s:10:"OddBgColor";a:1:{s:5:"Value";s:7:"#F6F6F6";}s:9:"EvenColor";a:1:{s:5:"Value";s:7:"#000000";}s:11:"EvenBgColor";a:1:{s:5:"Value";s:7:"#EBEBEB";}s:9:"TreeColor";a:1:{s:5:"Value";s:7:"#000000";}s:14:"TreeHoverColor";a:1:{s:5:"Value";s:7:"#009FF0";}s:13:"TreeHighColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:18:"TreeHighHoverColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:15:"TreeHighBgColor";a:1:{s:5:"Value";s:7:"#4A92CE";}s:11:"TreeBgColor";a:1:{s:5:"Value";s:7:"#DCECF6";}}', 1325154311, 1, 1); +INSERT INTO AdminSkins VALUES (DEFAULT, 'Default', '/* General elements */\r\n\r\nhtml {\r\n height: 100%;\r\n}\r\n\r\nbody {\r\n font-family: verdana,arial,helvetica,sans-serif;\r\n color: #000000;\r\n overflow-x: auto; overflow-y: auto;\r\n margin: 0px 0px 0px 0px;\r\n text-decoration: none;\r\n}\r\n\r\nbody, td {\r\n /* fix for Firefox, when font-size was not inherited in table cells */\r\n font-size: 9pt;\r\n}\r\n\r\na {\r\n color: #006699;\r\n text-decoration: none;\r\n}\r\n\r\na:hover {\r\n color: #009ff0;\r\n text-decoration: none;\r\n}\r\n\r\nform {\r\n display: inline;\r\n}\r\n\r\nimg { border: 0px; }\r\n\r\nbody.height-100 {\r\n height: 100%;\r\n}\r\n\r\nbody.regular-body {\r\n margin: 0px 10px 5px 10px;\r\n color: #000000;\r\n background-color: @@SectionBgColor@@;\r\n}\r\n\r\nbody.edit-popup {\r\n margin: 0px 0px 0px 0px;\r\n}\r\n\r\ntable.collapsed {\r\n border-collapse: collapse;\r\n}\r\n\r\n.bordered, table.bordered, .bordered-no-bottom {\r\n border: 1px solid #000000 !important;\r\n border-top-width: 0px;\r\n border-collapse: collapse;\r\n}\r\n\r\n.bordered-no-bottom {\r\n border-top-width: 1px;\r\n border-bottom: none;\r\n}\r\n\r\n.login-table td {\r\n padding: 1px;\r\n}\r\n\r\n.disabled {\r\n background-color: #ebebeb;\r\n}\r\n\r\n/* Head frame */\r\ntable.head-table {\r\n background: url(''@@base_url@@/core/admin_templates/img/top_frame/right_background.png'') top right @@HeadBgColor@@ no-repeat;\r\n}\r\n\r\n.head-table tr td, .head-table tr td a {\r\n color: @@HeadColor@@\r\n}\r\n\r\ndiv#extra_toolbar td.button-active {\r\n background: url(''@@base_url@@/core/admin_templates/img/top_frame/toolbar_button_background.gif'') bottom left repeat-x;\r\n height: 22px;\r\n}\r\n\r\ndiv#extra_toolbar td.button-active a {\r\n color: black;\r\n text-decoration: none;\r\n}\r\n\r\ntd.kx-block-header, .head-table tr td.kx-block-header{\r\n color: @@HeadBarColor@@;\r\n background: url(''@@base_url@@/core/admin_templates/img/top_frame/toolbar_background.gif'') repeat-x top left;\r\n /*background-color: @@HeadBarBgColor@@;*/\r\n padding-left: 7px;\r\n padding-right: 7px;\r\n}\r\n\r\na.kx-header-link {\r\n text-decoration: underline;\r\n font-weight: bold;\r\n color: #0080C8;\r\n}\r\n\r\na.kx-header-link:hover {\r\n color: #FFCB05;\r\n text-decoration: none;\r\n}\r\n\r\n.kx-secondary-foreground {\r\n color: #FFFFFF;\r\n /*background-color: @@HeadBarBgColor@@;*/\r\n}\r\n\r\n.kx-login-button {\r\n background-color: #2D79D6;\r\n color: #FFFFFF;\r\n}\r\n\r\n/* General form button (yellow) */\r\n.button {\r\n font-size: 12px;\r\n font-weight: normal;\r\n color: #000000;\r\n background: url(''@@base_url@@/core/admin_templates/img/button_back.gif'') #f9eeae repeat-x;\r\n text-decoration: none;\r\n}\r\n\r\n/* Disabled (grayed-out) form button */\r\n.button-disabled {\r\n font-size: 12px;\r\n font-weight: normal;\r\n color: #676767;\r\n background: url(''@@base_url@@/core/admin_templates/img/button_back_disabled.gif'') #f9eeae repeat-x;\r\n text-decoration: none;\r\n}\r\n\r\n/* Tabs bar */\r\n\r\n.tab, .tab-active {\r\n background-color: #F0F1EB;\r\n padding: 3px 7px 2px 7px;\r\n border-top: 1px solid black;\r\n border-left: 1px solid black;\r\n border-right: 1px solid black;\r\n margin-left: 3px !important;\r\n white-space: nowrap;\r\n}\r\n\r\n.tab-active {\r\n background-color: #4487D9;\r\n}\r\n\r\n.tab a {\r\n color: #4487D9;\r\n font-weight: bold;\r\n}\r\n\r\n.tab-active a {\r\n color: #FFFFFF;\r\n font-weight: bold;\r\n}\r\n\r\na.scroll-left, a.scroll-right {\r\n cursor: pointer;\r\n display: block;\r\n float: left;\r\n height: 18px;\r\n margin: 0px 1px;\r\n width: 18px;\r\n}\r\n\r\na.scroll-left {\r\n background: transparent url(''@@base_url@@/core/admin_templates/img/tabs/left.png'') no-repeat scroll 0 0;\r\n}\r\n\r\na.scroll-right {\r\n background: transparent url(''@@base_url@@/core/admin_templates/img/tabs/right.png'') no-repeat scroll 0 0;\r\n}\r\n\r\na.disabled {\r\n visibility: hidden !important;\r\n}\r\n\r\na.scroll-left:hover, a.scroll-right:hover {\r\n background-position: 0 -18px;\r\n}\r\n\r\ntd.scroll-right-container {\r\n width: 20px;\r\n}\r\n\r\ntd.scroll-right-container.disabled, td.scroll-right-container.disabled * {\r\n width: 0px;\r\n margin: 0px;\r\n}\r\n\r\ntd.scroll-right-container.disabled br {\r\n display: none;\r\n}\r\n\r\n/* Toolbar */\r\n\r\n.toolbar {\r\n font-size: 8pt;\r\n border: 1px solid #000000;\r\n border-width: 0px 1px 1px 1px;\r\n background-color: @@ToolbarBgColor@@;\r\n border-collapse: collapse;\r\n}\r\n\r\n.toolbar td {\r\n height: 100%;\r\n}\r\n\r\n.toolbar-button, .toolbar-button-disabled, .toolbar-button-over {\r\n float: left;\r\n text-align: center;\r\n font-size: 8pt;\r\n padding: 5px 5px 5px 5px;\r\n vertical-align: middle;\r\n color: #006F99;\r\n}\r\n\r\n.toolbar-button-over {\r\n color: #000;\r\n}\r\n\r\n.toolbar-button-disabled {\r\n color: #444;\r\n}\r\n\r\n/* Scrollable Grids */\r\n\r\n\r\n.layout-only-table td {\r\n border: none !important;\r\n}\r\n\r\n/* Main Grid class */\r\n.grid-scrollable {\r\n padding: 0px;\r\n border: 1px solid black !important;\r\n border-top: none !important;\r\n}\r\n\r\n/* Div generated by js, which contains all the scrollable grid elements, affects the style of scrollable area without data (if there are too few rows) */\r\n.grid-container {\r\n background-color: #fff;\r\n}\r\n\r\n.grid-container table {\r\n border-collapse: collapse;\r\n}\r\n\r\n/* Inner div generated in each data-cell */\r\n.grid-cell-div {\r\n overflow: hidden;\r\n height: auto;\r\n}\r\n\r\n/* Main row definition */\r\n.grid-data-row td, .grid-data-row-selected td, .grid-data-row-even-selected td, .grid-data-row-mouseover td, .table-color1, .table-color2, .grid-edit-table .edit-form-odd > td, .grid-edit-table .edit-form-even > td {\r\n font-weight: normal;\r\n color: @@OddColor@@;\r\n background-color: @@OddBgColor@@;\r\n padding: 3px 5px 3px 5px;\r\n overflow: hidden;\r\n border-right: 1px solid #c9c9c9;\r\n}\r\n.grid-data-row-even td, .table-color2, .grid-edit-table .edit-form-even > td {\r\n background-color: @@EvenBgColor@@;\r\n color: @@EvenColor@@;\r\n}\r\n.grid-data-row td a, .grid-data-row-selected td a, .grid-data-row-mouseover td a {\r\n text-decoration: underline;\r\n}\r\n\r\n/* mouse-over rows */\r\n.grid-data-row-mouseover td, table tr.grid-data-row[_row_highlighted] td {\r\n background: #FFFDF4;\r\n}\r\n\r\n/* Selected row, applies to both checkbox and data areas */\r\n.grid-data-row-selected td, table tr.grid-data-row[_row_selected] td {\r\n background: #FEF2D6;\r\n}\r\n\r\n.grid-data-row-even-selected td, .grid-data-row-even[_row_selected] td {\r\n background: #FFF7E0;\r\n}\r\n\r\n/* General header cell definition */\r\n.grid-header-row td {\r\n font-weight: bold;\r\n background-color: @@ColumnTitlesBgColor@@;\r\n text-decoration: none;\r\n padding: 3px 5px 3px 5px;\r\n color: @@ColumnTitlesColor@@;\r\n border-right: none;\r\n text-align: left;\r\n vertical-align: middle !important;\r\n white-space: nowrap;\r\n border-right: 1px solid #777;\r\n}\r\n\r\n/* Filters row */\r\ntr.grid-header-row-1 td {\r\n background-color: @@FiltersBgColor@@;\r\n border-bottom: 1px solid black;\r\n}\r\n\r\n/* Grid Filters */\r\ntable.range-filter {\r\n width: 100%;\r\n}\r\n\r\n.range-filter td {\r\n padding: 0px 0px 2px 2px !important;\r\n border: none !important;\r\n font-size: 8pt !important;\r\n font-weight: normal !important;\r\n text-align: left;\r\n color: #000000 !important;\r\n}\r\n\r\ninput.filter, select.filter, input.filter-active, select.filter-active {\r\n margin-bottom: 0px;\r\n border: 1px solid #aaa;\r\n}\r\n\r\ninput.filter-active {\r\n background-color: #FFFF00;\r\n}\r\n\r\nselect.filter-active {\r\n background-color: #FFFF00;\r\n}\r\n\r\ndiv.filter, div.filter-active {\r\n background-color: white;\r\n border: 1px solid #AAAAAA;\r\n color: black;\r\n font-weight: normal;\r\n padding: 3px;\r\n}\r\n\r\ndiv.filter-active {\r\n background-color: #FFFF00;\r\n}\r\n\r\ndiv.multioptions_filter {\r\n position: absolute;\r\n z-index: 100;\r\n color: black;\r\n background-color: white;\r\n border: 1px solid black;\r\n padding: 3px 5px;\r\n display: none;\r\n vertical-align: middle;\r\n}\r\n\r\n/* Column titles row */\r\ntr.grid-header-row-0 td {\r\n height: 25px;\r\n font-weight: bold;\r\n background-color: @@ColumnTitlesBgColor@@;\r\n color: @@ColumnTitlesColor@@;\r\n border-bottom: 1px solid black;\r\n}\r\n\r\ntr.grid-header-row-0 td a {\r\n color: @@ColumnTitlesColor@@;\r\n}\r\n\r\ntr.grid-header-row-0 td a:hover {\r\n color: #FFCC00;\r\n}\r\n\r\n\r\n.grid-footer-row td {\r\n background-color: #D7D7D7;\r\n font-weight: bold;\r\n border-right: 1px solid #C9C9C9;\r\n padding: 3px 5px 3px 5px;\r\n}\r\n\r\ntd.grid-header-last-cell, td.grid-data-last-cell, td.grid-footer-last-cell {\r\n border-right: none !important;\r\n}\r\n\r\ntd.grid-data-col-0, td.grid-data-col-0 div {\r\n text-align: center;\r\n vertical-align: middle !important;\r\n}\r\n\r\ntr.grid-header-row-1 td.grid-header-col-1 {\r\n text-align: center;\r\n vertical-align: middle !important;\r\n}\r\n\r\ntr.grid-header-row-1 td.grid-header-col-1 div {\r\n display: table-cell;\r\n vertical-align: middle;\r\n}\r\n\r\n.grid-status-bar {\r\n border: 1px solid black;\r\n border-top: none;\r\n padding: 0px;\r\n width: 100%;\r\n border-collapse: collapse;\r\n height: 30px;\r\n}\r\n\r\n.grid-status-bar td {\r\n background-color: @@TitleBarBgColor@@;\r\n color: @@TitleBarColor@@;\r\n font-size: 11pt;\r\n font-weight: normal;\r\n padding: 2px 8px 2px 8px;\r\n}\r\n\r\n/* /Scrollable Grids */\r\n\r\n\r\n/* Forms */\r\ntable.edit-form {\r\n border: none;\r\n border-top-width: 0px !important;\r\n border-collapse: collapse;\r\n width: 100%;\r\n}\r\n\r\n.edit-form-odd, .edit-form-even {\r\n padding: 0px;\r\n}\r\n\r\n.subsectiontitle {\r\n font-size: 10pt;\r\n font-weight: bold;\r\n background-color: #4A92CE;\r\n color: #fff;\r\n height: 25px;\r\n border-top: 1px solid black;\r\n vertical-align: middle;\r\n}\r\n\r\n/* remove top-border from first sub-section element */\r\ntable.edit-form .subsectiontitle:first-child, table.bordered .subsectiontitle:first-child {\r\n border-top-width: 0;\r\n}\r\n\r\n.subsectiontitle td {\r\n vertical-align: middle;\r\n /*padding: 3px 5px 3px 5px;*/\r\n padding: 1px 5px;\r\n}\r\n\r\n.label-cell {\r\n background: #DEE7F6 url(''@@base_url@@/core/admin_templates/img/bgr_input_name_line.gif'') no-repeat right bottom;\r\n font: 12px arial, sans-serif;\r\n padding: 4px 20px;\r\n width: 160px;\r\n}\r\n\r\n.control-mid {\r\n width: 13px;\r\n border-left: 1px solid #7A95C2;\r\n background: #fff url(''@@base_url@@/core/admin_templates/img/bgr_mid.gif'') repeat-x left bottom;\r\n}\r\n\r\n.control-cell {\r\n font: 11px arial, sans-serif;\r\n padding: 4px 10px 5px 5px;\r\n background: #fff url(''@@base_url@@/core/admin_templates/img/bgr_input_line.gif'') no-repeat left bottom;\r\n width: auto;\r\n vertical-align: middle;\r\n}\r\n\r\n.label-cell-filler {\r\n background: #DEE7F6 none;\r\n}\r\n.control-mid-filler {\r\n background: #fff none;\r\n border-left: 1px solid #7A95C2;\r\n}\r\n.control-cell-filler {\r\n background: #fff none;\r\n}\r\n\r\n.error {\r\n color: red;\r\n}\r\n.error-cell {\r\n color: red;\r\n}\r\n\r\n.field-required {\r\n color: red;\r\n}\r\n\r\n.warning-table {\r\n background-color: #F0F1EB;\r\n border: 1px solid #000000;\r\n border-collapse: collapse;\r\n border-top-width: 0px;\r\n}\r\n\r\n.form-notice, .form-warning {\r\n font-size: 11px;\r\n}\r\n\r\n.form-warning {\r\n color: red;\r\n}\r\n\r\n.form-notice {\r\n color: green;\r\n}\r\n\r\n.priority {\r\n color: red;\r\n padding-left: 1px;\r\n padding-right: 1px;\r\n font-size: 11px;\r\n}\r\n\r\n.small-statistics {\r\n font-size: 11px;\r\n color: #707070;\r\n}\r\n\r\n.req-note {\r\n font-style: italic;\r\n color: #333;\r\n}\r\n\r\n#scroll_container table.tableborder {\r\n border-collapse: separate\r\n}\r\n\r\n/* Uploader */\r\n.uploader-queue div.file {\r\n font-size: 11px;\r\n border: 1px solid #7F99C5;\r\n padding: 3px;\r\n background-color: #DEE7F6;\r\n margin-bottom: 2px;\r\n}\r\n\r\n.uploader-queue .left {\r\n float: left;\r\n vertical-align: top;\r\n}\r\n\r\n.uploader-queue .file-label {\r\n margin-left: 5px;\r\n}\r\n\r\n.uploader-queue .preview .delete-checkbox {\r\n margin-top: -3px;\r\n}\r\n\r\n.uploader-queue .progress-container {\r\n margin: 2px 5px 0px 5px;\r\n}\r\n\r\n.uploader-queue .progress-empty {\r\n width: 150px;\r\n height: 9px;\r\n border: 1px solid black;\r\n background: url(''@@base_url@@/core/admin_templates/img/progress_left.gif'') repeat-x;\r\n}\r\n\r\n.uploader-queue .progress-full {\r\n height: 9px;\r\n background: url(''@@base_url@@/core/admin_templates/img/progress_done.gif'');\r\n}\r\n\r\n.uploader-queue .thumbnail {\r\n /*margin-bottom: 2px;*/\r\n border: 1px solid black;\r\n background-color: grey;\r\n}\r\n\r\n/* To be sorted */\r\nspan#category_path, span#category_path a {\r\n color: #FFFFFF;\r\n}\r\n\r\nspan#category_path a {\r\n text-decoration: underline;\r\n}\r\n\r\n/* Section title, right to the big icon */\r\n.admintitle {\r\n font-size: 16pt;\r\n font-weight: bold;\r\n color: @@SectionColor@@;\r\n text-decoration: none;\r\n}\r\n\r\n/* Left side of bluebar */\r\n.header_left_bg {\r\n background-color: @@TitleBarBgColor@@;\r\n background-image: none;\r\n padding-left: 5px;\r\n}\r\n\r\n/* Right side of bluebar */\r\n.tablenav, tablenav a {\r\n font-size: 11pt;\r\n font-weight: bold;\r\n color: @@TitleBarColor@@;\r\n\r\n text-decoration: none;\r\n background-color: @@TitleBarBgColor@@;\r\n background-image: none;\r\n}\r\n\r\n/* Section title in the bluebar * -- why ''link''? :S */\r\n.tablenav_link {\r\n font-size: 11pt;\r\n font-weight: bold;\r\n color: @@TitleBarColor@@;\r\n text-decoration: none;\r\n}\r\n\r\n/* Active page in top and bottom bluebars pagination */\r\n.current_page {\r\n font-size: 10pt;\r\n font-weight: bold;\r\n background-color: #fff;\r\n color: #2D79D6;\r\n padding: 3px 2px 3px 3px;\r\n}\r\n\r\n/* Other pages and arrows in pagination on blue */\r\n.nav_url {\r\n font-size: 10pt;\r\n font-weight: bold;\r\n color: #fff;\r\n padding: 3px 2px 3px 3px;\r\n}\r\n\r\n/* Tree */\r\n.tree-body {\r\n background-color: @@TreeBgColor@@;\r\n height: 100%\r\n}\r\n\r\n.tree_head.td, .tree_head, .tree_head:hover {\r\n font-weight: bold;\r\n font-size: 10px;\r\n color: #FFFFFF;\r\n font-family: Verdana, Arial;\r\n text-decoration: none;\r\n}\r\n\r\n.tree {\r\n padding: 0px;\r\n border: none;\r\n border-collapse: collapse;\r\n}\r\n\r\n.tree tr td {\r\n padding: 0px;\r\n margin: 0px;\r\n font-family: helvetica, arial, verdana,;\r\n font-size: 11px;\r\n white-space: nowrap;\r\n}\r\n\r\n.tree tr td a {\r\n font-size: 11px;\r\n color: @@TreeColor@@;\r\n font-family: Helvetica, Arial, Verdana;\r\n text-decoration: none;\r\n padding: 2px;\r\n}\r\n\r\n.tree tr td a:hover, .tree tr td a.debug-only-item:hover {\r\n color: @@TreeHoverColor@@;\r\n}\r\n\r\n.tree tr.highlighted td a, .tree tr.highlighted td a.debug-only-item {\r\n color: @@TreeHighColor@@;\r\n background-color: @@TreeHighBgColor@@;\r\n}\r\n\r\n.tree tr.highlighted td a:hover {\r\n color: @@TreeHighHoverColor@@;\r\n}\r\n\r\n.tree tr td a.debug-only-item {\r\n color: grey;\r\n}\r\n\r\n/* Ajax Dropdown */\r\n.suggest-box {\r\n border: 1px solid #999;\r\n background-color: #fff;\r\n}\r\n\r\n.suggest-item, .suggest-item-over {\r\n padding: 1px 2px 0px 2px;\r\n font-family: arial,verdana;\r\n font-size: 12px;\r\n}\r\n\r\n.suggest-item-over {\r\n background-color: #3366CC;\r\n color: #fff;\r\n}\r\n\r\n/* Dashboard Summary Boxes */\r\n.summary-box {\r\n border: 1px solid black;\r\n margin-bottom: 4px;\r\n}\r\n\r\n.summary-box .title {\r\n color: white;\r\n font-weight: bold;\r\n padding: 6px 5px;\r\n vertical-align: middle;\r\n background-color: #4A92CE;\r\n border-bottom: 1px solid black;\r\n}\r\n\r\n.summary-box .content {\r\n padding: 4px;\r\n background-color: #F6F6F6;\r\n}\r\n\r\n.summary-box .group {\r\n border-bottom: 1px solid black;\r\n margin-bottom: 10px;\r\n padding: 0 0 10px 10px;\r\n}\r\n\r\n.summary-box .group.last {\r\n border-width: 0px;\r\n margin-bottom: 0;\r\n padding-bottom: 5px;\r\n}\r\n\r\n.summary-box h4 {\r\n margin: 0;\r\n padding: 0 0 3px 0;\r\n font-size: 11px;\r\n font-weight: bold;\r\n}\r\n\r\n.summary-box .hint {\r\n font-size: 10px;\r\n color: grey;\r\n margin-bottom: 3px;\r\n}\r\n\r\n.summary-box .hint .cache-key {\r\n margin-bottom: 7px;\r\n margin-left: 3px;\r\n}\r\n\r\n.summary-box ul {\r\n margin-top: 5px;\r\n margin-bottom: 3px;\r\n padding-left: 30px;\r\n}\r\n\r\n.summary-box li {\r\n padding-bottom: 4px;\r\n}', 'in-portal_logo_img.jpg', 'in-portal_logo_img2.jpg', 'in-portal_logo_login.gif', 'a:22:{s:11:"HeadBgColor";a:2:{s:11:"Description";s:27:"Head frame background color";s:5:"Value";s:7:"#007BF4";}s:9:"HeadColor";a:2:{s:11:"Description";s:21:"Head frame text color";s:5:"Value";s:7:"#FFFFFF";}s:14:"SectionBgColor";a:2:{s:11:"Description";s:28:"Section bar background color";s:5:"Value";s:7:"#FFFFFF";}s:12:"SectionColor";a:2:{s:11:"Description";s:22:"Section bar text color";s:5:"Value";s:7:"#2D79D6";}s:12:"HeadBarColor";a:1:{s:5:"Value";s:7:"#000000";}s:14:"HeadBarBgColor";a:1:{s:5:"Value";s:7:"#1961B8";}s:13:"TitleBarColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:15:"TitleBarBgColor";a:1:{s:5:"Value";s:7:"#2D79D6";}s:14:"ToolbarBgColor";a:1:{s:5:"Value";s:7:"#F0F1EB";}s:14:"FiltersBgColor";a:1:{s:5:"Value";s:7:"#D7D7D7";}s:17:"ColumnTitlesColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:19:"ColumnTitlesBgColor";a:1:{s:5:"Value";s:7:"#999999";}s:8:"OddColor";a:1:{s:5:"Value";s:7:"#000000";}s:10:"OddBgColor";a:1:{s:5:"Value";s:7:"#F6F6F6";}s:9:"EvenColor";a:1:{s:5:"Value";s:7:"#000000";}s:11:"EvenBgColor";a:1:{s:5:"Value";s:7:"#EBEBEB";}s:9:"TreeColor";a:1:{s:5:"Value";s:7:"#000000";}s:14:"TreeHoverColor";a:1:{s:5:"Value";s:7:"#009FF0";}s:13:"TreeHighColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:18:"TreeHighHoverColor";a:1:{s:5:"Value";s:7:"#FFFFFF";}s:15:"TreeHighBgColor";a:1:{s:5:"Value";s:7:"#4A92CE";}s:11:"TreeBgColor";a:1:{s:5:"Value";s:7:"#DCECF6";}}', 1325154311, 1, 1); INSERT INTO LocalesList VALUES (1, '0x0436', 'Afrikaans (South Africa)', 'af-ZA', 'Latn', '1252'), @@ -924,78 +924,78 @@ (207, '0x046a', 'Yoruba (Nigeria)', 'yo-NG', '', ''), (208, '0x0435', 'Zulu/isiZulu (South Africa)', 'zu-ZA', 'Latn', '1252'); -INSERT INTO SearchConfig VALUES ('Category', 'NewItem', 0, 1, 'lu_fielddesc_category_newitem', 'lc_field_newitem', 'In-Portal', 'la_text_category', 18, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'PopItem', 0, 1, 'lu_fielddesc_category_popitem', 'lc_field_popitem', 'In-Portal', 'la_text_category', 19, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'HotItem', 0, 1, 'lu_fielddesc_category_hotitem', 'lc_field_hotitem', 'In-Portal', 'la_text_category', 17, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'MetaDescription', 0, 1, 'lu_fielddesc_category_metadescription', 'lc_field_MetaDescription', 'In-Portal', 'la_text_category', 16, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'ParentPath', 0, 1, 'lu_fielddesc_category_parentpath', 'lc_field_ParentPath', 'In-Portal', 'la_text_category', 15, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'ResourceId', 0, 1, 'lu_fielddesc_category_resourceid', 'lc_field_resourceid', 'In-Portal', 'la_text_category', 14, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'CreatedById', 0, 1, 'lu_fielddesc_category_createdbyid', 'lc_field_createdbyid', 'In-Portal', 'la_text_category', 13, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'CachedNavbar', 0, 1, 'lu_fielddesc_category_cachednavbar', 'lc_field_CachedNavBar', 'In-Portal', 'la_text_category', 12, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'CachedDescendantCatsQty', 0, 1, 'lu_fielddesc_category_cacheddescendantcatsqty', 'lc_field_CachedDescendantCatsQty', 'In-Portal', 'la_text_category', 11, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'MetaKeywords', 0, 1, 'lu_fielddesc_category_metakeywords', 'lc_field_MetaKeywords', 'In-Portal', 'la_text_category', 10, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'Priority', 0, 1, 'lu_fielddesc_category_priority', 'lc_field_priority', 'In-Portal', 'la_text_category', 9, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'Status', 0, 1, 'lu_fielddesc_category_status', 'lc_field_status', 'In-Portal', 'la_text_category', 7, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'EditorsPick', 0, 1, 'lu_fielddesc_category_editorspick', 'lc_field_EditorsPick', 'In-Portal', 'la_text_category', 6, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'CreatedOn', 0, 1, 'lu_fielddesc_category_createdon', 'lc_field_createdon', 'In-Portal', 'la_text_category', 5, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'Description', 1, 1, 'lu_fielddesc_category_description', 'lc_field_description', 'In-Portal', 'la_text_category', 4, DEFAULT, 2, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'Name', 1, 1, 'lu_fielddesc_category_name', 'lc_field_name', 'In-Portal', 'la_text_category', 3, DEFAULT, 2, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'ParentId', 0, 1, 'lu_fielddesc_category_parentid', 'lc_field_ParentId', 'In-Portal', 'la_text_category', 2, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'CategoryId', 0, 1, 'lu_fielddesc_category_categoryid', 'lc_field_CategoryId', 'In-Portal', 'la_text_category', 0, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'Modified', 0, 1, 'lu_fielddesc_category_modified', 'lc_field_modified', 'In-Portal', 'la_text_category', 20, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('Category', 'ModifiedById', 0, 1, 'lu_fielddesc_category_modifiedbyid', 'lc_field_modifiedbyid', 'In-Portal', 'la_text_category', 21, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'NewItem', 0, 1, 'lu_fielddesc_category_newitem', 'lc_field_newitem', 'In-Portal', 'la_text_category', 18, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'PopItem', 0, 1, 'lu_fielddesc_category_popitem', 'lc_field_popitem', 'In-Portal', 'la_text_category', 19, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'HotItem', 0, 1, 'lu_fielddesc_category_hotitem', 'lc_field_hotitem', 'In-Portal', 'la_text_category', 17, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'MetaDescription', 0, 1, 'lu_fielddesc_category_metadescription', 'lc_field_MetaDescription', 'In-Portal', 'la_text_category', 16, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'ParentPath', 0, 1, 'lu_fielddesc_category_parentpath', 'lc_field_ParentPath', 'In-Portal', 'la_text_category', 15, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'ResourceId', 0, 1, 'lu_fielddesc_category_resourceid', 'lc_field_resourceid', 'In-Portal', 'la_text_category', 14, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'CreatedById', 0, 1, 'lu_fielddesc_category_createdbyid', 'lc_field_createdbyid', 'In-Portal', 'la_text_category', 13, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'CachedNavbar', 0, 1, 'lu_fielddesc_category_cachednavbar', 'lc_field_CachedNavBar', 'In-Portal', 'la_text_category', 12, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'CachedDescendantCatsQty', 0, 1, 'lu_fielddesc_category_cacheddescendantcatsqty', 'lc_field_CachedDescendantCatsQty', 'In-Portal', 'la_text_category', 11, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'MetaKeywords', 0, 1, 'lu_fielddesc_category_metakeywords', 'lc_field_MetaKeywords', 'In-Portal', 'la_text_category', 10, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'Priority', 0, 1, 'lu_fielddesc_category_priority', 'lc_field_priority', 'In-Portal', 'la_text_category', 9, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'Status', 0, 1, 'lu_fielddesc_category_status', 'lc_field_status', 'In-Portal', 'la_text_category', 7, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'EditorsPick', 0, 1, 'lu_fielddesc_category_editorspick', 'lc_field_EditorsPick', 'In-Portal', 'la_text_category', 6, DEFAULT, 0, 'boolean', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'CreatedOn', 0, 1, 'lu_fielddesc_category_createdon', 'lc_field_createdon', 'In-Portal', 'la_text_category', 5, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'Description', 1, 1, 'lu_fielddesc_category_description', 'lc_field_description', 'In-Portal', 'la_text_category', 4, DEFAULT, 2, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'Name', 1, 1, 'lu_fielddesc_category_name', 'lc_field_name', 'In-Portal', 'la_text_category', 3, DEFAULT, 2, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'ParentId', 0, 1, 'lu_fielddesc_category_parentid', 'lc_field_ParentId', 'In-Portal', 'la_text_category', 2, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'CategoryId', 0, 1, 'lu_fielddesc_category_categoryid', 'lc_field_CategoryId', 'In-Portal', 'la_text_category', 0, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'Modified', 0, 1, 'lu_fielddesc_category_modified', 'lc_field_modified', 'In-Portal', 'la_text_category', 20, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Categories', 'ModifiedById', 0, 1, 'lu_fielddesc_category_modifiedbyid', 'lc_field_modifiedbyid', 'In-Portal', 'la_text_category', 21, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'PortalUserId', -1, 0, 'lu_fielddesc_user_portaluserid', 'lu_field_portaluserid', 'In-Portal', 'la_text_user', 0, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Username', -1, 0, 'lu_fielddesc_user_login', 'lu_field_login', 'In-Portal', 'la_text_user', 1, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Password', -1, 0, 'lu_fielddesc_user_password', 'lu_field_password', 'In-Portal', 'la_text_user', 2, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'TimeZone', -1, 0, 'lu_fielddesc_user_tz', 'lu_field_tz', 'In-Portal', 'la_text_user', 17, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'dob', -1, 0, 'lu_fielddesc_user_dob', 'lu_field_dob', 'In-Portal', 'la_text_user', 16, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Modified', -1, 0, 'lu_fielddesc_user_modified', 'lc_field_modified', 'In-Portal', 'la_text_user', 15, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Status', -1, 0, 'lu_fielddesc_user_status', 'lc_field_status', 'In-Portal', 'la_text_user', 14, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'ResourceId', -1, 0, 'lu_fielddesc_user_resourceid', 'lc_field_resourceid', 'In-Portal', 'la_text_user', 13, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Country', -1, 0, 'lu_fielddesc_user_country', 'lu_field_country', 'In-Portal', 'la_text_user', 12, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Zip', -1, 0, 'lu_fielddesc_user_zip', 'lu_field_zip', 'In-Portal', 'la_text_user', 11, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'State', -1, 0, 'lu_fielddesc_user_state', 'lu_field_state', 'In-Portal', 'la_text_user', 10, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'City', -1, 0, 'lu_fielddesc_user_city', 'lu_field_city', 'In-Portal', 'la_text_user', 9, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Street', -1, 0, 'lu_fielddesc_user_street', 'lu_field_street', 'In-Portal', 'la_text_user', 8, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Phone', -1, 0, 'lu_fielddesc_user_phone', 'lu_field_phone', 'In-Portal', 'la_text_user', 7, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'CreatedOn', -1, 0, 'lu_fielddesc_user_createdon', 'lc_field_createdon', 'In-Portal', 'la_text_user', 6, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'Email', -1, 0, 'lu_fielddesc_user_email', 'lu_field_email', 'In-Portal', 'la_text_user', 5, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'LastName', -1, 0, 'lu_fielddesc_user_lastname', 'lu_field_lastname', 'In-Portal', 'la_text_user', 4, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO SearchConfig VALUES ('PortalUser', 'FirstName', -1, 0, 'lu_fielddesc_user_firstname', 'lu_field_firstname', 'In-Portal', 'la_text_user', 3, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'PortalUserId', -1, 0, 'lu_fielddesc_user_portaluserid', 'lu_field_portaluserid', 'In-Portal', 'la_text_user', 0, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Username', -1, 0, 'lu_fielddesc_user_login', 'lu_field_login', 'In-Portal', 'la_text_user', 1, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Password', -1, 0, 'lu_fielddesc_user_password', 'lu_field_password', 'In-Portal', 'la_text_user', 2, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'TimeZone', -1, 0, 'lu_fielddesc_user_tz', 'lu_field_tz', 'In-Portal', 'la_text_user', 17, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'dob', -1, 0, 'lu_fielddesc_user_dob', 'lu_field_dob', 'In-Portal', 'la_text_user', 16, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Modified', -1, 0, 'lu_fielddesc_user_modified', 'lc_field_modified', 'In-Portal', 'la_text_user', 15, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Status', -1, 0, 'lu_fielddesc_user_status', 'lc_field_status', 'In-Portal', 'la_text_user', 14, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'ResourceId', -1, 0, 'lu_fielddesc_user_resourceid', 'lc_field_resourceid', 'In-Portal', 'la_text_user', 13, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Country', -1, 0, 'lu_fielddesc_user_country', 'lu_field_country', 'In-Portal', 'la_text_user', 12, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Zip', -1, 0, 'lu_fielddesc_user_zip', 'lu_field_zip', 'In-Portal', 'la_text_user', 11, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'State', -1, 0, 'lu_fielddesc_user_state', 'lu_field_state', 'In-Portal', 'la_text_user', 10, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'City', -1, 0, 'lu_fielddesc_user_city', 'lu_field_city', 'In-Portal', 'la_text_user', 9, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Street', -1, 0, 'lu_fielddesc_user_street', 'lu_field_street', 'In-Portal', 'la_text_user', 8, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Phone', -1, 0, 'lu_fielddesc_user_phone', 'lu_field_phone', 'In-Portal', 'la_text_user', 7, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'CreatedOn', -1, 0, 'lu_fielddesc_user_createdon', 'lc_field_createdon', 'In-Portal', 'la_text_user', 6, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'Email', -1, 0, 'lu_fielddesc_user_email', 'lu_field_email', 'In-Portal', 'la_text_user', 5, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'LastName', -1, 0, 'lu_fielddesc_user_lastname', 'lu_field_lastname', 'In-Portal', 'la_text_user', 4, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); +INSERT INTO SearchConfig VALUES ('Users', 'FirstName', -1, 0, 'lu_fielddesc_user_firstname', 'lu_field_firstname', 'In-Portal', 'la_text_user', 3, DEFAULT, 0, 'text', NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT count(*) FROM <%prefix%>Category WHERE Status=1 ', NULL, 'la_prompt_ActiveCategories', '0', '1'); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT count(*) FROM <%prefix%>PortalUser WHERE Status=1 ', NULL, 'la_prompt_ActiveUsers', '0', '1'); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT count(*) FROM <%prefix%>UserSession', NULL, 'la_prompt_CurrentSessions', '0', '1'); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) as CategoryCount FROM <%prefix%>Category', NULL, 'la_prompt_TotalCategories', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS ActiveCategories FROM <%prefix%>Category WHERE Status = 1', NULL, 'la_prompt_ActiveCategories', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS PendingCategories FROM <%prefix%>Category WHERE Status = 2', NULL, 'la_prompt_PendingCategories', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS DisabledCategories FROM <%prefix%>Category WHERE Status = 0', NULL, 'la_prompt_DisabledCategories', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS NewCategories FROM <%prefix%>Category WHERE (NewItem = 1) OR ( (UNIX_TIMESTAMP() - CreatedOn) <= <%m:config name="Category_DaysNew"%>*86400 AND (NewItem = 2) )', NULL, 'la_prompt_NewCategories', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) FROM <%prefix%>Category WHERE EditorsPick = 1', NULL, 'la_prompt_CategoryEditorsPick', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT <%m:post_format field="MAX(CreatedOn)" type="date"%> FROM <%prefix%>Category', NULL, 'la_prompt_NewestCategoryDate', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT <%m:post_format field="MAX(Modified)" type="date"%> FROM <%prefix%>Category', NULL, 'la_prompt_LastCategoryUpdate', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS TotalUsers FROM <%prefix%>PortalUser', NULL, 'la_prompt_TopicsUsers', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS ActiveUsers FROM <%prefix%>PortalUser WHERE Status = 1', NULL, 'la_prompt_UsersActive', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS PendingUsers FROM <%prefix%>PortalUser WHERE Status = 2', NULL, 'la_prompt_UsersPending', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS DisabledUsers FROM <%prefix%>PortalUser WHERE Status = 0', NULL, 'la_prompt_UsersDisabled', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT <%m:post_format field="MAX(CreatedOn)" type="date"%> FROM <%prefix%>PortalUser', NULL, 'la_prompt_NewestUserDate', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT( DISTINCT LOWER( Country ) ) FROM <%prefix%>PortalUser WHERE LENGTH(Country) > 0', NULL, 'la_prompt_UsersUniqueCountries', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT( DISTINCT LOWER( State ) ) FROM <%prefix%>PortalUser WHERE LENGTH(State) > 0', NULL, 'la_prompt_UsersUniqueStates', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS TotalUserGroups FROM <%prefix%>PortalGroup', NULL, 'la_prompt_TotalUserGroups', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS BannedUsers FROM <%prefix%>PortalUser WHERE IsBanned = 1', NULL, 'la_prompt_BannedUsers', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS NonExipedSessions FROM <%prefix%>UserSession WHERE Status = 1', NULL, 'la_prompt_NonExpiredSessions', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS ThemeCount FROM <%prefix%>Theme', NULL, 'la_prompt_ThemeCount', 0, 2); -INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS RegionsCount FROM <%prefix%>Language', NULL, 'la_prompt_RegionsCount', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT count(*) FROM <%prefix%>Categories WHERE Status=1 ', NULL, 'la_prompt_ActiveCategories', '0', '1'); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT count(*) FROM <%prefix%>Users WHERE Status=1 ', NULL, 'la_prompt_ActiveUsers', '0', '1'); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT count(*) FROM <%prefix%>UserSessions', NULL, 'la_prompt_CurrentSessions', '0', '1'); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) as CategoryCount FROM <%prefix%>Categories', NULL, 'la_prompt_TotalCategories', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS ActiveCategories FROM <%prefix%>Categories WHERE Status = 1', NULL, 'la_prompt_ActiveCategories', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS PendingCategories FROM <%prefix%>Categories WHERE Status = 2', NULL, 'la_prompt_PendingCategories', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS DisabledCategories FROM <%prefix%>Categories WHERE Status = 0', NULL, 'la_prompt_DisabledCategories', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS NewCategories FROM <%prefix%>Categories WHERE (NewItem = 1) OR ( (UNIX_TIMESTAMP() - CreatedOn) <= <%m:config name="Category_DaysNew"%>*86400 AND (NewItem = 2) )', NULL, 'la_prompt_NewCategories', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) FROM <%prefix%>Categories WHERE EditorsPick = 1', NULL, 'la_prompt_CategoryEditorsPick', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT <%m:post_format field="MAX(CreatedOn)" type="date"%> FROM <%prefix%>Categories', NULL, 'la_prompt_NewestCategoryDate', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT <%m:post_format field="MAX(Modified)" type="date"%> FROM <%prefix%>Categories', NULL, 'la_prompt_LastCategoryUpdate', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS TotalUsers FROM <%prefix%>Users', NULL, 'la_prompt_TopicsUsers', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS ActiveUsers FROM <%prefix%>Users WHERE Status = 1', NULL, 'la_prompt_UsersActive', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS PendingUsers FROM <%prefix%>Users WHERE Status = 2', NULL, 'la_prompt_UsersPending', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS DisabledUsers FROM <%prefix%>Users WHERE Status = 0', NULL, 'la_prompt_UsersDisabled', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT <%m:post_format field="MAX(CreatedOn)" type="date"%> FROM <%prefix%>Users', NULL, 'la_prompt_NewestUserDate', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT( DISTINCT LOWER( Country ) ) FROM <%prefix%>Users WHERE LENGTH(Country) > 0', NULL, 'la_prompt_UsersUniqueCountries', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT( DISTINCT LOWER( State ) ) FROM <%prefix%>Users WHERE LENGTH(State) > 0', NULL, 'la_prompt_UsersUniqueStates', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS TotalUserGroups FROM <%prefix%>UserGroups', NULL, 'la_prompt_TotalUserGroups', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS BannedUsers FROM <%prefix%>Users WHERE IsBanned = 1', NULL, 'la_prompt_BannedUsers', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS NonExipedSessions FROM <%prefix%>UserSessions WHERE Status = 1', NULL, 'la_prompt_NonExpiredSessions', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS ThemeCount FROM <%prefix%>Themes', NULL, 'la_prompt_ThemeCount', 0, 2); +INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', 'SELECT COUNT(*) AS RegionsCount FROM <%prefix%>Languages', NULL, 'la_prompt_RegionsCount', 0, 2); INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', '<%m:sql_action sql="SHOW+TABLES" action="COUNT" field="*"%>', NULL, 'la_prompt_TablesCount', 0, 2); INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', '<%m:sql_action sql="SHOW+TABLE+STATUS" action="SUM" field="Rows"%>', NULL, 'la_prompt_RecordsCount', 0, 2); INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', '<%m:custom_action sql="empty" action="SysFileSize"%>', NULL, 'la_prompt_SystemFileSize', 0, 2); INSERT INTO StatItem VALUES (DEFAULT, 'In-Portal', '<%m:sql_action sql="SHOW+TABLE+STATUS" action="SUM" format_as="file" field="Data_length"%>', NULL, 'la_prompt_DataSize', 0, 2); -INSERT INTO Counters VALUES (DEFAULT, 'members_count', 'SELECT COUNT(*) FROM <%PREFIX%>PortalUser WHERE Status = 1', NULL , NULL , '3600', '0', '|PortalUser|'); -INSERT INTO Counters VALUES (DEFAULT, 'members_online', 'SELECT COUNT(*) FROM <%PREFIX%>UserSession WHERE PortalUserId > 0', NULL , NULL , '3600', '0', '|UserSession|'); -INSERT INTO Counters VALUES (DEFAULT, 'guests_online', 'SELECT COUNT(*) FROM <%PREFIX%>UserSession WHERE PortalUserId <= 0', NULL , NULL , '3600', '0', '|UserSession|'); -INSERT INTO Counters VALUES (DEFAULT, 'users_online', 'SELECT COUNT(*) FROM <%PREFIX%>UserSession', NULL , NULL , '3600', '0', '|UserSession|'); +INSERT INTO Counters VALUES (DEFAULT, 'members_count', 'SELECT COUNT(*) FROM <%PREFIX%>Users WHERE Status = 1', NULL , NULL , '3600', '0', '|Users|'); +INSERT INTO Counters VALUES (DEFAULT, 'members_online', 'SELECT COUNT(*) FROM <%PREFIX%>UserSessions WHERE PortalUserId > 0', NULL , NULL , '3600', '0', '|UserSessions|'); +INSERT INTO Counters VALUES (DEFAULT, 'guests_online', 'SELECT COUNT(*) FROM <%PREFIX%>UserSessions WHERE PortalUserId <= 0', NULL , NULL , '3600', '0', '|UserSessions|'); +INSERT INTO Counters VALUES (DEFAULT, 'users_online', 'SELECT COUNT(*) FROM <%PREFIX%>UserSessions', NULL , NULL , '3600', '0', '|UserSessions|'); INSERT INTO StopWords VALUES (90, '~'),(152, 'on'),(157, 'see'),(156, 'put'),(128, 'and'),(154, 'or'),(155, 'other'),(153, 'one'),(126, 'as'),(127, 'at'),(125, 'are'),(91, '!'),(92, '@'),(93, '#'),(94, '$'),(95, '%'),(96, '^'),(97, '&'),(98, '*'),(99, '('),(100, ')'),(101, '-'),(102, '_'),(103, '='),(104, '+'),(105, '['),(106, '{'),(107, ']'),(108, '}'),(109, '\\'),(110, '|'),(111, ';'),(112, ':'),(113, ''''),(114, '"'),(115, '<'),(116, '.'),(117, '>'),(118, '/'),(119, '?'),(120, 'ah'),(121, 'all'),(122, 'also'),(123, 'am'),(124, 'an'),(151, 'of'),(150, 'note'),(149, 'not'),(148, 'no'),(147, 'may'),(146, 'its'),(145, 'it'),(144, 'is'),(143, 'into'),(142, 'in'),(141, 'had'),(140, 'has'),(139, 'have'),(138, 'from'),(137, 'form'),(136, 'for'),(135, 'end'),(134, 'each'),(133, 'can'),(132, 'by'),(130, 'be'),(131, 'but'),(129, 'any'),(158, 'that'),(159, 'the'),(160, 'their'),(161, 'there'),(162, 'these'),(163, 'they'),(164, 'this'),(165, 'through'),(166, 'thus'),(167, 'to'),(168, 'two'),(169, 'too'),(170, 'up'),(171, 'where'),(172, 'which'),(173, 'with'),(174, 'were'),(175, 'was'),(176, 'you'),(177, 'yet'); Index: core/install/install_schema.sql =================================================================== --- core/install/install_schema.sql (revision 14994) +++ core/install/install_schema.sql (working copy) @@ -1,4 +1,4 @@ -CREATE TABLE PermissionConfig ( +CREATE TABLE CategoryPermissionsConfig ( PermissionConfigId int(11) NOT NULL auto_increment, PermissionName varchar(255) NOT NULL default '', Description varchar(255) NOT NULL default '', @@ -19,7 +19,7 @@ UNIQUE KEY PermIndex (Permission,GroupId,CatId,`Type`) ); -CREATE TABLE CustomField ( +CREATE TABLE CustomFields ( CustomFieldId int(11) NOT NULL auto_increment, `Type` int(11) NOT NULL default '0', FieldName varchar(255) NOT NULL default '', @@ -43,7 +43,7 @@ KEY DefaultValue (DefaultValue) ); -CREATE TABLE ConfigurationValues ( +CREATE TABLE SystemSettings ( VariableId int(11) NOT NULL AUTO_INCREMENT, VariableName varchar(255) NOT NULL DEFAULT '', VariableValue text, @@ -83,7 +83,7 @@ KEY MailingId (MailingId) ); -CREATE TABLE Events ( +CREATE TABLE EmailEvents ( EventId int(11) NOT NULL AUTO_INCREMENT, `Event` varchar(40) NOT NULL DEFAULT '', ReplacementTags text, @@ -128,7 +128,7 @@ lastid int(11) default NULL ); -CREATE TABLE Language ( +CREATE TABLE Languages ( LanguageId int(11) NOT NULL AUTO_INCREMENT, PackName varchar(40) NOT NULL DEFAULT '', LocalName varchar(40) NOT NULL DEFAULT '', @@ -173,7 +173,7 @@ KEY LoadOrder (LoadOrder) ); -CREATE TABLE PersistantSessionData ( +CREATE TABLE UserPersistentSessionData ( VariableId bigint(20) NOT NULL AUTO_INCREMENT, PortalUserId int(11) NOT NULL DEFAULT '0', VariableName varchar(255) NOT NULL DEFAULT '', @@ -183,7 +183,7 @@ KEY VariableName (VariableName) ); -CREATE TABLE Phrase ( +CREATE TABLE LanguageLabels ( PhraseId int(11) NOT NULL AUTO_INCREMENT, Phrase varchar(255) NOT NULL DEFAULT '', PhraseKey varchar(255) NOT NULL DEFAULT '', @@ -225,7 +225,7 @@ KEY StylesheetId (StylesheetId) ); -CREATE TABLE PortalGroup ( +CREATE TABLE UserGroups ( GroupId int(11) NOT NULL AUTO_INCREMENT, `Name` varchar(255) NOT NULL DEFAULT '', Description varchar(255) DEFAULT NULL, @@ -242,7 +242,7 @@ KEY CreatedOn (CreatedOn) ); -CREATE TABLE PortalUser ( +CREATE TABLE Users ( PortalUserId int(11) NOT NULL AUTO_INCREMENT, Username varchar(255) NOT NULL, `Password` varchar(255) DEFAULT 'd41d8cd98f00b204e9800998ecf8427e', @@ -288,14 +288,14 @@ KEY Username (Username) ); -CREATE TABLE PortalUserCustomData ( +CREATE TABLE UserCustomData ( CustomDataId int(11) NOT NULL auto_increment, ResourceId int(10) unsigned NOT NULL default '0', KEY ResourceId (ResourceId), PRIMARY KEY (CustomDataId) ); -CREATE TABLE SessionData ( +CREATE TABLE UserSessionData ( SessionKey varchar(50) NOT NULL DEFAULT '', VariableName varchar(255) NOT NULL DEFAULT '', VariableValue longtext, @@ -304,7 +304,7 @@ KEY VariableName (VariableName) ); -CREATE TABLE Theme ( +CREATE TABLE Themes ( ThemeId int(11) NOT NULL AUTO_INCREMENT, `Name` varchar(40) NOT NULL DEFAULT '', Enabled int(11) NOT NULL DEFAULT '1', @@ -339,7 +339,7 @@ KEY TemplateAlias (TemplateAlias) ); -CREATE TABLE UserGroup ( +CREATE TABLE UserGroupRelations ( PortalUserId int(11) NOT NULL DEFAULT '0', GroupId int(11) NOT NULL DEFAULT '0', MembershipExpires int(10) unsigned DEFAULT NULL, @@ -350,7 +350,7 @@ KEY ExpirationReminderSent (ExpirationReminderSent) ); -CREATE TABLE UserSession ( +CREATE TABLE UserSessions ( SessionKey int(10) unsigned NOT NULL DEFAULT '0', LastAccessed int(10) unsigned NOT NULL DEFAULT '0', PortalUserId int(11) NOT NULL DEFAULT '-2', @@ -380,7 +380,7 @@ KEY `timestamp` (`timestamp`) ); -CREATE TABLE Cache ( +CREATE TABLE SystemCache ( VarName varchar(255) NOT NULL default '', Data longtext, Cached int(11) default NULL, @@ -406,7 +406,7 @@ KEY l1_Name (l1_Name(5)) ); -CREATE TABLE Category ( +CREATE TABLE Categories ( CategoryId int(11) NOT NULL AUTO_INCREMENT, `Type` int(11) NOT NULL DEFAULT '1', SymLinkCategoryId int(10) unsigned DEFAULT NULL, @@ -535,7 +535,7 @@ KEY Filename (Filename) ); -CREATE TABLE PermCache ( +CREATE TABLE CategoryPermissionsCache ( PermCacheId int(11) NOT NULL auto_increment, CategoryId int(11) NOT NULL default '0', PermId int(11) NOT NULL default '0', @@ -571,7 +571,7 @@ KEY LastCounted (LastCounted) ); -CREATE TABLE Skins ( +CREATE TABLE AdminSkins ( SkinId int(11) NOT NULL AUTO_INCREMENT, `Name` varchar(255) DEFAULT NULL, CSS text, @@ -607,7 +607,7 @@ KEY MasterPrefix (MasterPrefix) ); -CREATE TABLE SessionLogs ( +CREATE TABLE UserSessionLogs ( SessionLogId bigint(20) NOT NULL AUTO_INCREMENT, PortalUserId int(11) NOT NULL DEFAULT '0', SessionId int(10) NOT NULL DEFAULT '0', @@ -727,7 +727,7 @@ PRIMARY KEY (LocaleId) ); -CREATE TABLE BanRules ( +CREATE TABLE UserBanRules ( RuleId int(11) NOT NULL auto_increment, RuleType tinyint(4) NOT NULL default '0', ItemField varchar(255) default NULL, @@ -754,7 +754,7 @@ PRIMARY KEY (CountCacheId) ); -CREATE TABLE Favorites ( +CREATE TABLE UserFavorites ( FavoriteId int(11) NOT NULL auto_increment, PortalUserId int(11) NOT NULL default '0', ResourceId int(11) NOT NULL default '0', @@ -766,7 +766,7 @@ KEY ItemTypeId (ItemTypeId) ); -CREATE TABLE Images ( +CREATE TABLE CatalogImages ( ImageId int(11) NOT NULL auto_increment, ResourceId int(11) NOT NULL default '0', Url varchar(255) NOT NULL default '', @@ -788,7 +788,7 @@ KEY Priority (Priority) ); -CREATE TABLE ItemRating ( +CREATE TABLE CatalogRatings ( RatingId int(11) NOT NULL auto_increment, IPAddress varchar(255) NOT NULL default '', CreatedOn INT UNSIGNED NULL DEFAULT NULL, @@ -800,7 +800,7 @@ KEY RatingValue (RatingValue) ); -CREATE TABLE ItemReview ( +CREATE TABLE CatalogReviews ( ReviewId int(11) NOT NULL AUTO_INCREMENT, CreatedOn int(10) unsigned DEFAULT NULL, ReviewText longtext, @@ -866,7 +866,7 @@ KEY Module (Module) ); -CREATE TABLE ItemFiles ( +CREATE TABLE CatalogFiles ( FileId int(11) NOT NULL AUTO_INCREMENT, ResourceId int(11) unsigned NOT NULL DEFAULT '0', FileName varchar(255) NOT NULL DEFAULT '', @@ -882,7 +882,7 @@ KEY `Status` (`Status`) ); -CREATE TABLE Relationship ( +CREATE TABLE CatalogRelationships ( RelationshipId int(11) NOT NULL auto_increment, SourceId int(11) default NULL, TargetId int(11) default NULL, @@ -929,7 +929,7 @@ KEY CustomFieldId (CustomFieldId) ); -CREATE TABLE SearchLog ( +CREATE TABLE SearchLogs ( SearchLogId int(11) NOT NULL auto_increment, Keyword varchar(255) NOT NULL default '', Indices bigint(20) NOT NULL default '0', @@ -978,7 +978,7 @@ KEY `Status` (`Status`) ); -CREATE TABLE Visits ( +CREATE TABLE UserVisits ( VisitId int(11) NOT NULL AUTO_INCREMENT, VisitDate int(10) unsigned DEFAULT NULL, Referer varchar(255) NOT NULL DEFAULT '', @@ -1001,7 +1001,7 @@ KEY VarName (VarName) ); -CREATE TABLE RelatedSearches ( +CREATE TABLE CategoryRelatedSearches ( RelatedSearchId int(11) NOT NULL auto_increment, ResourceId int(11) NOT NULL default '0', Keyword varchar(255) NOT NULL default '', @@ -1122,7 +1122,7 @@ KEY MessageId (MessageId) ); -CREATE TABLE SubmissionLog ( +CREATE TABLE FormSubmissionReplies ( SubmissionLogId int(11) NOT NULL AUTO_INCREMENT, FormSubmissionId int(10) unsigned NOT NULL, FromEmail varchar(255) NOT NULL DEFAULT '', @@ -1153,7 +1153,7 @@ KEY MessageId (MessageId) ); -CREATE TABLE Drafts ( +CREATE TABLE FormSubmissionReplyDrafts ( DraftId int(11) NOT NULL AUTO_INCREMENT, FormSubmissionId int(10) unsigned NOT NULL DEFAULT '0', CreatedOn int(10) unsigned DEFAULT NULL, Index: core/install/install_toolkit.php =================================================================== --- core/install/install_toolkit.php (revision 14999) +++ core/install/install_toolkit.php (working copy) @@ -141,7 +141,7 @@ /* @var $prerequisite_object InPortalPrerequisites */ // some errors possible - return $prerequisite_object->CheckPrerequisites($versions, $mode); + return is_object($prerequisite_object) ? $prerequisite_object->CheckPrerequisites($versions, $mode) : Array (); } /** @@ -156,15 +156,14 @@ $prerequisite_object =& $this->getPrerequisiteObject($module_path); /* @var $prerequisite_object InPortalPrerequisites */ - return $prerequisite_object->$method(); + return is_object($prerequisite_object) ? $prerequisite_object->$method() : false; } /** * Returns prerequisite object to be used for checks * * @param string $module_path - * @param string $versions - * @return bool + * @return kHelper * @access protected */ protected function &getPrerequisiteObject($module_path) @@ -231,7 +230,7 @@ function saveConfigValues($config) { foreach ($config as $config_var => $value) { - $sql = 'UPDATE ' . TABLE_PREFIX . 'ConfigurationValues + $sql = 'UPDATE ' . TABLE_PREFIX . 'SystemSettings SET VariableValue = ' . $this->Conn->qstr($value) . ' WHERE VariableName = ' . $this->Conn->qstr($config_var); $this->Conn->Query($sql); @@ -851,14 +850,14 @@ $db =& $this->Application->GetADODBConnection(); $sql = 'SELECT FieldName, CustomFieldId - FROM ' . TABLE_PREFIX . 'CustomField + FROM ' . TABLE_PREFIX . 'CustomFields WHERE Type = ' . $item_type . ' AND IsSystem = 0'; // config is not read here yet :( $this->Application->getUnitOption('p', 'ItemType'); $custom_fields = $db->GetCol($sql, 'CustomFieldId'); foreach ($custom_fields as $cf_id => $cf_name) { $sql = 'UPDATE ' . TABLE_PREFIX . 'SearchConfig SET CustomFieldId = ' . $cf_id . ' - WHERE (TableName = "CustomField") AND (LOWER(ModuleName) = "' . $module_name . '") AND (FieldName = ' . $db->qstr($cf_name) . ')'; + WHERE (TableName = "CustomFields") AND (LOWER(ModuleName) = "' . $module_name . '") AND (FieldName = ' . $db->qstr($cf_name) . ')'; $db->Query($sql); } Index: core/install/remove_schema.sql =================================================================== --- core/install/remove_schema.sql (revision 14988) +++ core/install/remove_schema.sql (working copy) @@ -1,55 +1,55 @@ -DROP TABLE PermissionConfig; +DROP TABLE CategoryPermissionsConfig; DROP TABLE Permissions; -DROP TABLE CustomField; -DROP TABLE ConfigurationValues; +DROP TABLE CustomFields; +DROP TABLE SystemSettings; DROP TABLE EmailQueue; -DROP TABLE Events; +DROP TABLE EmailEvents; DROP TABLE IdGenerator; -DROP TABLE Language; +DROP TABLE Languages; DROP TABLE Modules; -DROP TABLE PersistantSessionData; -DROP TABLE Phrase; +DROP TABLE UserPersistentSessionData; +DROP TABLE LanguageLabels; DROP TABLE PhraseCache; -DROP TABLE PortalGroup; -DROP TABLE PortalUser; -DROP TABLE PortalUserCustomData; -DROP TABLE SessionData; -DROP TABLE Theme; +DROP TABLE UserGroups; +DROP TABLE Users; +DROP TABLE UserCustomData; +DROP TABLE UserSessionData; +DROP TABLE Themes; DROP TABLE ThemeFiles; -DROP TABLE UserGroup; -DROP TABLE UserSession; +DROP TABLE UserGroupRelations; +DROP TABLE UserSessions; DROP TABLE EmailLog; -DROP TABLE Cache; +DROP TABLE SystemCache; DROP TABLE CountryStates; -DROP TABLE Category; +DROP TABLE Categories; DROP TABLE CategoryCustomData; DROP TABLE CategoryItems; -DROP TABLE PermCache; +DROP TABLE CategoryPermissionsCache; DROP TABLE Stylesheets; DROP TABLE PopupSizes; DROP TABLE Counters; -DROP TABLE Skins; +DROP TABLE AdminSkins; DROP TABLE ChangeLogs; -DROP TABLE SessionLogs; +DROP TABLE UserSessionLogs; DROP TABLE StatisticsCapture; DROP TABLE SlowSqlCapture; DROP TABLE ScheduledTasks; DROP TABLE SpellingDictionary; DROP TABLE Thesaurus; DROP TABLE LocalesList; -DROP TABLE BanRules; +DROP TABLE UserBanRules; DROP TABLE CountCache; -DROP TABLE Favorites; -DROP TABLE Images; -DROP TABLE ItemRating; -DROP TABLE ItemReview; +DROP TABLE UserFavorites; +DROP TABLE CatalogImages; +DROP TABLE CatalogRatings; +DROP TABLE CatalogReviews; DROP TABLE ItemFilters; DROP TABLE SpamReports; DROP TABLE ItemTypes; -DROP TABLE ItemFiles; -DROP TABLE Relationship; +DROP TABLE CatalogFiles; +DROP TABLE CatalogRelationships; DROP TABLE SearchConfig; -DROP TABLE SearchLog; +DROP TABLE SearchLogs; DROP TABLE SpamControl; DROP TABLE StatItem; DROP TABLE SysCache; @@ -57,17 +57,17 @@ DROP TABLE TagAttributes; DROP TABLE ImportScripts; DROP TABLE StylesheetSelectors; -DROP TABLE Visits; +DROP TABLE UserVisits; DROP TABLE ImportCache; -DROP TABLE RelatedSearches; +DROP TABLE CategoryRelatedSearches; DROP TABLE StopWords; DROP TABLE MailingLists; DROP TABLE PageContent; DROP TABLE PageRevisions; DROP TABLE FormFields; DROP TABLE FormSubmissions; -DROP TABLE SubmissionLog; -DROP TABLE Drafts; +DROP TABLE FormSubmissionReplies; +DROP TABLE FormSubmissionReplyDrafts; DROP TABLE Forms; DROP TABLE Semaphores; DROP TABLE CachedUrls; Index: core/install/steps_db.xml =================================================================== --- core/install/steps_db.xml (revision 14988) +++ core/install/steps_db.xml (working copy) @@ -205,7 +205,7 @@ to connect to the database.

If you would like In-Portal to use a table prefix, enter it in the field provided. This prefix can be any text which can be used in the names of tables on your system. The characters entered in this field are placed before the names of the tables used by In-Portal. - For example, if you enter "inp_" into the prefix field, the table named Category will be named inp_Category.

]]> + For example, if you enter "inp_" into the prefix field, the table named Categories will be named inp_Categories.

]]> System Requirements Check option should be used to ensure proper system behavior in the current environment.]]> Index: core/install/upgrades.php =================================================================== --- core/install/upgrades.php (revision 15001) +++ core/install/upgrades.php (working copy) @@ -1797,7 +1797,7 @@ function transformSortings() { $sql = 'SELECT VariableName, PortalUserId - FROM ' . TABLE_PREFIX . 'PersistantSessionData + FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE VariableName LIKE "%_Sort1.%"'; $sortings = $this->Conn->Query($sql); @@ -1817,7 +1817,7 @@ $old_variable_names = $this->Conn->qstrArray($old_variable_names); $sql = 'SELECT VariableValue, VariableName - FROM ' . TABLE_PREFIX . 'PersistantSessionData + FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE PortalUserId = ' . $user_id . ' AND VariableName IN (' . implode(',', $old_variable_names) . ')'; $sorting_data = $this->Conn->GetCol($sql, 'VariableName'); @@ -1838,10 +1838,10 @@ 'VariableValue' => serialize($new_sorting), ); - $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'PersistantSessionData'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'UserPersistentSessionData'); // delete sortings, that were already processed - $sql = 'DELETE FROM ' . TABLE_PREFIX . 'PersistantSessionData + $sql = 'DELETE FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE PortalUserId = ' . $user_id . ' AND VariableName IN (' . implode(',', $old_variable_names) . ')'; $this->Conn->Query($sql); } @@ -1867,6 +1867,7 @@ $delete_ids = Array (); $ml_helper->createFields('phrases'); $languages = $ml_helper->getLanguages(); + $phrase_table = $this->Application->getUnitOption('phrases', 'TableName'); foreach ($source_phrases as $phrase_key => $phrase_info) { $target_phrase_key = $target_prefix . substr($phrase_key, strlen($source_prefix)); @@ -1883,12 +1884,12 @@ } $delete_ids[] = $phrase_info['PhraseId']; - $this->Conn->doUpdate($fields_hash, TABLE_PREFIX . 'Phrase', 'PhraseId = ' . $target_phrases[$target_phrase_key]['PhraseId']); + $this->Conn->doUpdate($fields_hash, $phrase_table, 'PhraseId = ' . $target_phrases[$target_phrase_key]['PhraseId']); } // delete all column phrases, that were absorbed by field phrases if ( $delete_ids ) { - $sql = 'DELETE FROM ' . TABLE_PREFIX . 'Phrase + $sql = 'DELETE FROM ' . $phrase_table . ' WHERE PhraseId IN (' . implode(',', $delete_ids) . ')'; $this->Conn->Query($sql); @@ -1907,7 +1908,7 @@ protected function getPhrasesByMask($mask) { $sql = 'SELECT * - FROM ' . TABLE_PREFIX . 'Phrase + FROM ' . $this->Application->getUnitOption('phrases', 'TableName') . ' WHERE PhraseKey LIKE ' . $this->Conn->qstr($mask); return $this->Conn->Query($sql, 'PhraseKey'); Index: core/install/upgrades.sql =================================================================== --- core/install/upgrades.sql (revision 14994) +++ core/install/upgrades.sql (working copy) @@ -2399,7 +2399,7 @@ DELETE FROM PersistantSessionData WHERE VariableName LIKE 'agent%'; -RENAME TABLE Agents TO ScheduledTasks; +RENAME TABLE <%TABLE_PREFIX%>Agents TO <%TABLE_PREFIX%>ScheduledTasks; ALTER TABLE ScheduledTasks CHANGE AgentId ScheduledTaskId INT(11) NOT NULL AUTO_INCREMENT, @@ -2526,9 +2526,71 @@ INSERT INTO ConfigurationValues VALUES(DEFAULT, 'UpdateCountersOnFilterChange', '1', 'In-Portal', 'in-portal:configure_categories', 'la_title_General', 'la_config_UpdateCountersOnFilterChange', 'checkbox', '', '', 10.15, 0, 0, NULL); -ALTER TABLE UserSession CHANGE `tz` `TimeZone` VARCHAR(255) NOT NULL; +# use new table name (see /core/install.php:390)! +ALTER TABLE UserSessions CHANGE `tz` `TimeZone` VARCHAR(255) NOT NULL; ALTER TABLE PortalUser CHANGE `tz` `TimeZone` VARCHAR(255) NOT NULL DEFAULT ''; UPDATE SearchConfig SET FieldName = 'TimeZone' WHERE FieldName = 'tz' AND TableName = 'PortalUser'; + +RENAME TABLE <%TABLE_PREFIX%>BanRules TO <%TABLE_PREFIX%>UserBanRules; +RENAME TABLE <%TABLE_PREFIX%>Cache TO <%TABLE_PREFIX%>SystemCache; +RENAME TABLE <%TABLE_PREFIX%>ConfigurationValues TO <%TABLE_PREFIX%>SystemSettings; +RENAME TABLE <%TABLE_PREFIX%>Category TO <%TABLE_PREFIX%>Categories; + +UPDATE ItemTypes SET SourceTable = 'Categories' WHERE ItemType = 1; +UPDATE ItemTypes SET SourceTable = 'Users' WHERE ItemType = 6; + +UPDATE SearchConfig SET TableName = 'Categories' WHERE TableName = 'Category'; +UPDATE SearchConfig SET TableName = 'CustomFields' WHERE TableName = 'CustomField'; +UPDATE SearchConfig SET TableName = 'Users' WHERE TableName = 'PortalUser'; + +UPDATE StatItem SET ValueSQL = REPLACE(ValueSQL, '<%prefix%>Category', '<%prefix%>Categories'); +UPDATE StatItem SET ValueSQL = REPLACE(ValueSQL, '<%prefix%>ItemReview', '<%prefix%>CatalogReviews'); +UPDATE StatItem SET ValueSQL = REPLACE(ValueSQL, '<%prefix%>Language', '<%prefix%>Languages'); +UPDATE StatItem SET ValueSQL = REPLACE(ValueSQL, '<%prefix%>PortalGroup', '<%prefix%>UserGroups'); +UPDATE StatItem SET ValueSQL = REPLACE(ValueSQL, '<%prefix%>PortalUser', '<%prefix%>Users'); +UPDATE StatItem SET ValueSQL = REPLACE(ValueSQL, '<%prefix%>Theme', '<%prefix%>Themes'); +UPDATE StatItem SET ValueSQL = REPLACE(ValueSQL, '<%prefix%>UserSession', '<%prefix%>UserSessions'); + +UPDATE SystemSettings SET ValueList = REPLACE(ValueList, 'CustomField', 'CustomFields'); +UPDATE SystemSettings SET ValueList = REPLACE(ValueList, 'PortalGroup', 'UserGroups'); + +UPDATE Counters +SET CountQuery = 'SELECT COUNT(*) FROM <%PREFIX%>Users WHERE Status = 1', TablesAffected = '|Users|' +WHERE `Name` = 'members_count'; + +UPDATE Counters +SET + CountQuery = REPLACE(CountQuery, '<%PREFIX%>UserSession', '<%PREFIX%>UserSessions'), + TablesAffected = REPLACE(TablesAffected, '|UserSession|', '|UserSessions|'); + +RENAME TABLE <%TABLE_PREFIX%>CustomField TO <%TABLE_PREFIX%>CustomFields; +RENAME TABLE <%TABLE_PREFIX%>Drafts TO <%TABLE_PREFIX%>FormSubmissionReplyDrafts; +RENAME TABLE <%TABLE_PREFIX%>Events TO <%TABLE_PREFIX%>EmailEvents; + +DELETE FROM PersistantSessionData WHERE VariableName LIKE '%custom_filter%'; + +RENAME TABLE <%TABLE_PREFIX%>Favorites TO <%TABLE_PREFIX%>UserFavorites; +RENAME TABLE <%TABLE_PREFIX%>Images TO <%TABLE_PREFIX%>CatalogImages; +RENAME TABLE <%TABLE_PREFIX%>ItemFiles TO <%TABLE_PREFIX%>CatalogFiles; +RENAME TABLE <%TABLE_PREFIX%>ItemRating TO <%TABLE_PREFIX%>CatalogRatings; +RENAME TABLE <%TABLE_PREFIX%>ItemReview TO <%TABLE_PREFIX%>CatalogReviews; +RENAME TABLE <%TABLE_PREFIX%>Language TO <%TABLE_PREFIX%>Languages; +RENAME TABLE <%TABLE_PREFIX%>PermCache TO <%TABLE_PREFIX%>CategoryPermissionsCache; +RENAME TABLE <%TABLE_PREFIX%>PermissionConfig TO <%TABLE_PREFIX%>CategoryPermissionsConfig; +RENAME TABLE <%TABLE_PREFIX%>Phrase TO <%TABLE_PREFIX%>LanguageLabels; +RENAME TABLE <%TABLE_PREFIX%>PortalGroup TO <%TABLE_PREFIX%>UserGroups; +RENAME TABLE <%TABLE_PREFIX%>PersistantSessionData TO <%TABLE_PREFIX%>UserPersistentSessionData; +RENAME TABLE <%TABLE_PREFIX%>PortalUser TO <%TABLE_PREFIX%>Users; +RENAME TABLE <%TABLE_PREFIX%>PortalUserCustomData TO <%TABLE_PREFIX%>UserCustomData; +RENAME TABLE <%TABLE_PREFIX%>RelatedSearches TO <%TABLE_PREFIX%>CategoryRelatedSearches; +RENAME TABLE <%TABLE_PREFIX%>Relationship TO <%TABLE_PREFIX%>CatalogRelationships; +RENAME TABLE <%TABLE_PREFIX%>SearchLog TO <%TABLE_PREFIX%>SearchLogs; +RENAME TABLE <%TABLE_PREFIX%>Skins TO <%TABLE_PREFIX%>AdminSkins; +RENAME TABLE <%TABLE_PREFIX%>SubmissionLog TO <%TABLE_PREFIX%>FormSubmissionReplies; +RENAME TABLE <%TABLE_PREFIX%>Theme TO <%TABLE_PREFIX%>Themes; +RENAME TABLE <%TABLE_PREFIX%>UserGroup TO <%TABLE_PREFIX%>UserGroupRelations; +RENAME TABLE <%TABLE_PREFIX%>Visits TO <%TABLE_PREFIX%>UserVisits; +RENAME TABLE <%TABLE_PREFIX%>SessionLogs TO <%TABLE_PREFIX%>UserSessionLogs; Index: core/install/utf.php =================================================================== --- core/install/utf.php (revision 14988) +++ core/install/utf.php (working copy) @@ -36,7 +36,7 @@ ini_set('max_execution_time', 0); // Convert language translation -$langs = $application->Conn->Query('SELECT * FROM '.TABLE_PREFIX.'Language', 'LanguageId'); +$langs = $application->Conn->Query('SELECT * FROM '.TABLE_PREFIX.'Languages', 'LanguageId'); foreach ($langs as $lang_id => $a_lang) { switch ( strtoupper($a_lang['Charset']) ) { case 'WINDOWS-1251': @@ -101,7 +101,7 @@ $application->Conn->Query($q); // copying value to utf - if ($table == TABLE_PREFIX.'Phrase' && $a_column['Field'] == 'Translation') { + if ($table == TABLE_PREFIX.'LanguageLabels' && $a_column['Field'] == 'Translation') { foreach ($langs as $lang_id => $a_lang) { $cast = $a_lang['mysql_charset']; if (!$cast) $cast = 'latin1'; @@ -145,4 +145,4 @@ } } -$application->Conn->Query('UPDATE '.TABLE_PREFIX.'Language SET Charset = \''.$target_charset.'\''); +$application->Conn->Query('UPDATE '.TABLE_PREFIX.'Languages SET Charset = \''.$target_charset.'\''); Index: core/kernel/application.php =================================================================== --- core/kernel/application.php (revision 14995) +++ core/kernel/application.php (working copy) @@ -2787,7 +2787,7 @@ default: $sql = 'SELECT GroupId - FROM ' . TABLE_PREFIX . 'UserGroup + FROM ' . TABLE_PREFIX . 'UserGroupRelations WHERE PortalUserId = ' . (int)$user_id; $res = $this->Conn->GetCol($sql); Index: core/kernel/db/cat_dbitem.php =================================================================== --- core/kernel/db/cat_dbitem.php (revision 14988) +++ core/kernel/db/cat_dbitem.php (working copy) @@ -457,13 +457,13 @@ function getPrimaryImageData() { $sql = 'SELECT * - FROM '.TABLE_PREFIX.'Images + FROM '.TABLE_PREFIX.'CatalogImages WHERE (ResourceId = '.$this->GetDBField('ResourceId').') AND (DefaultImg = 1)'; $image_data = $this->Conn->GetRow($sql); if (!$image_data) { // 2. no primary image, then get image with name "main" $sql = 'SELECT * - FROM '.TABLE_PREFIX.'Images + FROM '.TABLE_PREFIX.'CatalogImages WHERE (ResourceId = '.$this->GetDBField('ResourceId').') AND (Name = "main")'; $image_data = $this->Conn->GetRow($sql); } Index: core/kernel/db/cat_event_handler.php =================================================================== --- core/kernel/db/cat_event_handler.php (revision 14989) +++ core/kernel/db/cat_event_handler.php (working copy) @@ -450,8 +450,8 @@ $object->addCalculatedField('Relevance', 'search_result.Relevance'); $object->AddOrderField('search_result.Relevance', 'desc', true); - $type_clauses['search']['include'] = 'PrimaryCat = 1 AND ('.TABLE_PREFIX.'Category.Status = '.STATUS_ACTIVE.')'; - $type_clauses['search']['except'] = 'PrimaryCat = 1 AND ('.TABLE_PREFIX.'Category.Status = '.STATUS_ACTIVE.')'; + $type_clauses['search']['include'] = 'PrimaryCat = 1 AND ('.TABLE_PREFIX.'Categories.Status = '.STATUS_ACTIVE.')'; + $type_clauses['search']['except'] = 'PrimaryCat = 1 AND ('.TABLE_PREFIX.'Categories.Status = '.STATUS_ACTIVE.')'; $type_clauses['search']['having_filter'] = false; } @@ -580,7 +580,7 @@ return 'FALSE'; } - return TABLE_PREFIX.'Category.TreeLeft BETWEEN '.$tree_indexes['TreeLeft'].' AND '.$tree_indexes['TreeRight']; + return TABLE_PREFIX.'Categories.TreeLeft BETWEEN '.$tree_indexes['TreeLeft'].' AND '.$tree_indexes['TreeRight']; } /** @@ -702,7 +702,7 @@ } } else { - $object->addFilter('status_filter', '(%1$s.Status = ' . STATUS_ACTIVE . ') AND (' . TABLE_PREFIX . 'Category.Status = ' . STATUS_ACTIVE . ')'); + $object->addFilter('status_filter', '(%1$s.Status = ' . STATUS_ACTIVE . ') AND (' . TABLE_PREFIX . 'Categories.Status = ' . STATUS_ACTIVE . ')'); if ($pending_editing) { // if category item uses pending editing abilities, then in no cases show pending copies on front $object->addFilter('original_filter', '%1$s.OrgId = 0 OR %1$s.OrgId IS NULL'); @@ -1063,13 +1063,13 @@ // don't save keywords for each module separately, just one time // static variable can't help here, because each module uses it's own class instance ! if (!$this->Application->GetVar('search_logged')) { - $sql = 'UPDATE '.TABLE_PREFIX.'SearchLog + $sql = 'UPDATE '.TABLE_PREFIX.'SearchLogs SET Indices = Indices + 1 WHERE Keyword = '.$this->Conn->qstr($keywords).' AND SearchType = '.$search_type; // 0 - simple search, 1 - advanced search $this->Conn->Query($sql); if ($this->Conn->getAffectedRows() == 0) { $fields_hash = Array('Keyword' => $keywords, 'Indices' => 1, 'SearchType' => $search_type); - $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'SearchLog'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'SearchLogs'); } $this->Application->SetVar('search_logged', 1); @@ -1252,7 +1252,7 @@ $category_filter = $this->getCategoryLimitClause($category_id); if ($category_filter !== false) { $join_clauses[] = ' LEFT JOIN '.TABLE_PREFIX.'CategoryItems ON '.TABLE_PREFIX.'CategoryItems.ItemResourceId = '.$items_table.'.ResourceId'; - $join_clauses[] = ' LEFT JOIN '.TABLE_PREFIX.'Category ON '.TABLE_PREFIX.'Category.CategoryId = '.TABLE_PREFIX.'CategoryItems.CategoryId'; + $join_clauses[] = ' LEFT JOIN '.TABLE_PREFIX.'Categories ON '.TABLE_PREFIX.'Categories.CategoryId = '.TABLE_PREFIX.'CategoryItems.CategoryId'; $where_clause = '('.$this->getCategoryLimitClause($category_id).') AND '.$where_clause; } Index: core/kernel/db/cat_tag_processor.php =================================================================== --- core/kernel/db/cat_tag_processor.php (revision 14988) +++ core/kernel/db/cat_tag_processor.php (working copy) @@ -200,7 +200,7 @@ { $review_tag_processor =& $this->Application->recallObject('rev.item_TagProcessor'); /* @var $review_tag_processor kDBTagProcessor */ - + return $review_tag_processor->TotalRecords($params); } @@ -631,7 +631,7 @@ $sql = 'SELECT MAX(item_table.Modified) AS ModDate, MAX(item_table.CreatedOn) AS NewDate FROM ' . $this->Application->getUnitOption($this->Prefix, 'TableName') . ' item_table LEFT JOIN ' . TABLE_PREFIX . 'CategoryItems ci ON (item_table.ResourceId = ci.ItemResourceId) - LEFT JOIN ' . TABLE_PREFIX . 'Category c ON c.CategoryId = ci.CategoryId + LEFT JOIN ' . TABLE_PREFIX . 'Categories c ON c.CategoryId = ci.CategoryId WHERE c.TreeLeft BETWEEN ' . $tree_left . ' AND ' . $tree_right; } else { @@ -706,7 +706,7 @@ // get category list (permission based) $sql = 'SELECT c.'.$title_field.' AS CategoryName, c.'.$id_field.', c.l' . $this->Application->GetVar('m_lang') . '_CachedNavbar AS CachedNavbar FROM '.$table_name.' c - INNER JOIN '.TABLE_PREFIX.'PermCache perm_cache ON c.CategoryId = perm_cache.CategoryId + INNER JOIN '.TABLE_PREFIX.'CategoryPermissionsCache perm_cache ON c.CategoryId = perm_cache.CategoryId WHERE (ParentId = '.$category_id.') AND ('.$view_filter.') AND (perm_cache.PermId = '.$view_perm.') AND (c.Status = '.STATUS_ACTIVE.') ORDER BY c.'.$title_field.' ASC'; $categories = $this->Conn->Query($sql, $id_field); Index: core/kernel/languages/phrases_cache.php =================================================================== --- core/kernel/languages/phrases_cache.php (revision 14988) +++ core/kernel/languages/phrases_cache.php (working copy) @@ -170,7 +170,7 @@ } $sql = 'SELECT l' . $this->LanguageId . '_Translation AS Translation, l' . $this->LanguageId . '_HintTranslation AS HintTranslation, l' . $this->LanguageId . '_ColumnTranslation AS ColumnTranslation, PhraseKey - FROM ' . TABLE_PREFIX . 'Phrase + FROM ' . TABLE_PREFIX . 'LanguageLabels WHERE PhraseId IN (' . implode(',', $ids) . ') AND l' . $this->LanguageId . '_Translation IS NOT NULL'; $this->Phrases = $this->Conn->Query($sql, 'PhraseKey'); @@ -253,7 +253,7 @@ $language_id = $use_admin ? $this->AdminLanguageId : $this->LanguageId; $sql = 'SELECT PhraseId, l' . $language_id . '_Translation AS Translation, l' . $language_id . '_HintTranslation AS HintTranslation, l' . $language_id . '_ColumnTranslation AS ColumnTranslation - FROM ' . TABLE_PREFIX . 'Phrase + FROM ' . TABLE_PREFIX . 'LanguageLabels WHERE (PhraseKey = ' . $this->Conn->qstr($label) . ') AND (l' . $language_id . '_Translation IS NOT NULL)'; $res = $this->Conn->GetRow($sql); Index: core/kernel/managers/cache_manager.php =================================================================== --- core/kernel/managers/cache_manager.php (revision 14995) +++ core/kernel/managers/cache_manager.php (working copy) @@ -17,7 +17,7 @@ class kCacheManager extends kBase implements kiCacheable { /** - * Used variables from ConfigurationValues table + * Used variables from SystemSettings table * * @var Array * @access protected @@ -25,7 +25,7 @@ protected $configVariables = Array(); /** - * Used variables from ConfigurationValues table retrieved from unit cache + * Used variables from SystemSettings table retrieved from unit cache * * @var Array * @access protected @@ -65,6 +65,33 @@ ); /** + * Name of database table, where configuration settings are stored + * + * @var string + * @access protected + */ + protected $settingTableName = ''; + + /** + * Set's references to kApplication and kDBConnection class instances + * + * @param kApplication $application + * @access public + */ + public function __construct($application = null) + { + parent::__construct($application); + + $this->settingTableName = TABLE_PREFIX . 'SystemSettings'; + + if ( defined('IS_INSTALL') && IS_INSTALL ) { + // table substitution required, so "root" can perform login to upgrade to 5.2.0, where setting table was renamed + if ( !$this->Application->TableFound(TABLE_PREFIX . 'SystemSettings') ) { + $this->settingTableName = TABLE_PREFIX . 'ConfigurationValues'; + } + } + } + /** * Creates caching manager instance * * @access public @@ -153,7 +180,7 @@ } $sql = 'SELECT VariableValue, VariableName - FROM ' . TABLE_PREFIX . 'ConfigurationValues + FROM ' . $this->settingTableName . ' WHERE VariableId IN (' . implode(',', $this->originalConfigIDs) . ')'; $config_variables = $this->Conn->GetCol($sql, 'VariableName'); @@ -186,13 +213,13 @@ return $this->configVariables[$name]; } - if ( defined('IS_INSTALL') && IS_INSTALL && !$this->Application->TableFound('ConfigurationValues', true) ) { + if ( defined('IS_INSTALL') && IS_INSTALL && !$this->Application->TableFound($this->settingTableName, true) ) { return false; } $this->Conn->nextQueryCachable = true; $sql = 'SELECT VariableId, VariableValue - FROM ' . TABLE_PREFIX . 'ConfigurationValues + FROM ' . $this->settingTableName . ' WHERE VariableName = ' . $this->Conn->qstr($name); $res = $this->Conn->GetRow($sql); @@ -226,7 +253,7 @@ } $fields_hash = Array ('VariableValue' => $value); - $this->Conn->doUpdate($fields_hash, TABLE_PREFIX . 'ConfigurationValues', 'VariableName = ' . $this->Conn->qstr($name)); + $this->Conn->doUpdate($fields_hash, $this->settingTableName, 'VariableName = ' . $this->Conn->qstr($name)); if ( array_key_exists($name, $this->originalConfigVariables) && $value != $this->originalConfigVariables[$name] ) { $this->DeleteUnitCache(); @@ -425,7 +452,7 @@ $escaped_config_vars = $this->Conn->qstrArray($config_vars); $sql = 'SELECT VariableId, VariableName, VariableValue - FROM ' . TABLE_PREFIX . 'ConfigurationValues + FROM ' . $this->settingTableName . ' WHERE VariableName IN (' . implode(',', $escaped_config_vars) . ')'; $data = $this->Conn->Query($sql, 'VariableId'); @@ -606,7 +633,7 @@ $this->Conn->nextQueryCachable = true; $sql = 'SELECT Data, Cached, LifeTime - FROM ' . TABLE_PREFIX . 'Cache + FROM ' . TABLE_PREFIX . 'SystemCache WHERE VarName = ' . $this->Conn->qstr($name); $data = $this->Conn->GetRow($sql); @@ -616,7 +643,7 @@ // delete expired $this->Conn->nextQueryCachable = true; - $sql = 'DELETE FROM ' . TABLE_PREFIX . 'Cache + $sql = 'DELETE FROM ' . TABLE_PREFIX . 'SystemCache WHERE VarName = ' . $this->Conn->qstr($name); $this->Conn->Query($sql); @@ -666,7 +693,7 @@ ); $this->Conn->nextQueryCachable = true; - $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'Cache', 'REPLACE'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'SystemCache', 'REPLACE'); } /** @@ -699,7 +726,7 @@ */ public function deleteDBCache($name) { - $sql = 'DELETE FROM ' . TABLE_PREFIX . 'Cache + $sql = 'DELETE FROM ' . TABLE_PREFIX . 'SystemCache WHERE VarName = ' . $this->Conn->qstr($name); $this->Conn->Query($sql); } @@ -762,7 +789,7 @@ // this allows to save 2 sql queries for each category $this->Conn->nextQueryCachable = true; $sql = 'SELECT NamedParentPath, CachedTemplate, TreeLeft, TreeRight - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId = ' . (int)$category_id; $category_data = $this->Conn->GetRow($sql); Index: core/kernel/managers/rewrite_url_processor.php =================================================================== --- core/kernel/managers/rewrite_url_processor.php (revision 14988) +++ core/kernel/managers/rewrite_url_processor.php (working copy) @@ -230,7 +230,7 @@ // get expiration if ($vars['m_cat_id'] > 0) { $sql = 'SELECT PageExpiration - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId = ' . $vars['m_cat_id']; $expiration = $this->Conn->GetOne($sql); } @@ -492,7 +492,7 @@ $url_part = reset($url_parts); $sql = 'SELECT LanguageId, IF(LOWER(PackName) = ' . $this->Conn->qstr($url_part) . ', 2, PrimaryLang) AS SortKey - FROM ' . TABLE_PREFIX . 'Language + FROM ' . TABLE_PREFIX . 'Languages WHERE Enabled = 1 ORDER BY SortKey DESC'; $language_info = $this->Conn->GetRow($sql); @@ -534,7 +534,7 @@ $url_part = reset($url_parts); $sql = 'SELECT ThemeId, IF(LOWER(Name) = ' . $this->Conn->qstr($url_part) . ', 2, PrimaryTheme) AS SortKey, TemplateAliases - FROM ' . TABLE_PREFIX . 'Theme + FROM ' . TABLE_PREFIX . 'Themes WHERE Enabled = 1 ORDER BY SortKey DESC'; $theme_info = $this->Conn->GetRow($sql); @@ -694,7 +694,7 @@ $category = $this->Application->findModule('Var', $module_prefix, 'RootCat'); } $sql = 'SELECT c.ParentPath, c.CategoryId - FROM ' . TABLE_PREFIX . 'Category AS c + FROM ' . TABLE_PREFIX . 'Categories AS c WHERE c.CategoryId = ' . $category; $category = $this->Conn->GetRow($sql); } @@ -708,7 +708,7 @@ $query = ' SELECT ccd.l' . $primary_lang . '_cust_' . $item_template_field_id . ', FIND_IN_SET(c.CategoryId, ' . $this->Conn->qstr($parent_path) . ') AS Ord1, c.CategoryId, c.Name, ccd.l' . $primary_lang . '_cust_' . $item_template_field_id . ' - FROM ' . TABLE_PREFIX . 'Category AS c + FROM ' . TABLE_PREFIX . 'Categories AS c LEFT JOIN ' . TABLE_PREFIX . 'CategoryCustomData AS ccd ON ccd.ResourceId = c.ResourceId WHERE c.CategoryId IN (' . $parent_path . ') AND ccd.l' . $primary_lang . '_cust_' . $item_template_field_id . ' != \'\' @@ -722,7 +722,7 @@ /* @var $themes_helper kThemesHelper */ $sql = 'SELECT TemplateAliases - FROM ' . TABLE_PREFIX . 'Theme + FROM ' . TABLE_PREFIX . 'Themes WHERE ThemeId = ' . (int)$themes_helper->getCurrentThemeId(); $template_aliases = $this->Conn->GetOne($sql); @@ -757,7 +757,7 @@ } $sql = 'SELECT CustomFieldId - FROM ' . TABLE_PREFIX . 'CustomField + FROM ' . TABLE_PREFIX . 'CustomFields WHERE FieldName = ' . $this->Conn->qstr($module_prefix . '_ItemTemplate'); $item_template_field_id = $this->Conn->GetOne($sql); Index: core/kernel/nparser/template_cache.php =================================================================== --- core/kernel/nparser/template_cache.php (revision 14988) +++ core/kernel/nparser/template_cache.php (working copy) @@ -175,7 +175,7 @@ if ($this->_compileToDatabase) { $sql = 'SELECT * - FROM ' . TABLE_PREFIX . 'Cache + FROM ' . TABLE_PREFIX . 'SystemCache WHERE VarName = "' . $fname . '"'; $cached = $this->Conn->GetRow($sql); @@ -214,7 +214,7 @@ 'Cached' => adodb_mktime(), ); - $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'Cache', 'REPLACE'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'SystemCache', 'REPLACE'); return ; } @@ -246,7 +246,7 @@ if ($this->_compileToDatabase) { $sql = 'SELECT * - FROM ' . TABLE_PREFIX . 'Cache + FROM ' . TABLE_PREFIX . 'SystemCache WHERE VarName = "' . $pre_parsed['fname'] . '"'; $cached = $this->Conn->GetRow($sql); Index: core/kernel/processors/main_processor.php =================================================================== --- core/kernel/processors/main_processor.php (revision 14988) +++ core/kernel/processors/main_processor.php (working copy) @@ -431,7 +431,7 @@ if ( isset($params['formatted']) && $params['formatted'] ) { $sql = 'SELECT ValueList - FROM ' . TABLE_PREFIX . 'ConfigurationValues + FROM ' . TABLE_PREFIX . 'SystemSettings WHERE VariableName = ' . $this->Conn->qstr($config_name) . ' AND ElementType IN ("select", "radio")'; $value_list = $this->Conn->GetOne($sql); @@ -870,7 +870,7 @@ $group_access = true; if ($group) { $sql = 'SELECT GroupId - FROM '.TABLE_PREFIX.'PortalGroup + FROM '.TABLE_PREFIX.'UserGroups WHERE Name = '.$this->Conn->qstr($group); $group_id = $this->Conn->GetOne($sql); @@ -916,7 +916,7 @@ protected function IsMember($params) { $sql = 'SELECT GroupId - FROM ' . TABLE_PREFIX . 'PortalGroup + FROM ' . TABLE_PREFIX . 'UserGroups WHERE Name = ' . $this->Conn->qstr($params['group']); $group_id = $this->Conn->GetOne($sql); @@ -1195,11 +1195,11 @@ if ($this->Application->ConfigValue('UsePageHitCounter')) { // get current counte $sql = 'SELECT VariableValue - FROM '.TABLE_PREFIX.'ConfigurationValues + FROM '.TABLE_PREFIX.'SystemSettings WHERE VariableName = "PageHitCounter"'; $page_counter = (int)$this->Conn->GetOne($sql); - $sql = 'UPDATE LOW_PRIORITY '.TABLE_PREFIX.'ConfigurationValues + $sql = 'UPDATE LOW_PRIORITY '.TABLE_PREFIX.'SystemSettings SET VariableValue = '.($page_counter + 1).' WHERE VariableName = "PageHitCounter"'; $this->Conn->Query($sql); Index: core/kernel/session/inp_session_storage.php =================================================================== --- core/kernel/session/inp_session_storage.php (revision 14988) +++ core/kernel/session/inp_session_storage.php (working copy) @@ -21,8 +21,8 @@ { parent::Init($prefix, $special); - $this->TableName = TABLE_PREFIX.'UserSession'; - $this->SessionDataTable = TABLE_PREFIX.'SessionData'; + $this->TableName = TABLE_PREFIX.'UserSessions'; + $this->SessionDataTable = TABLE_PREFIX.'UserSessionData'; $this->IDField = 'SessionKey'; $this->TimestampField = 'LastAccessed'; $this->DataValueField = 'VariableValue'; Index: core/kernel/session/session.php =================================================================== --- core/kernel/session/session.php (revision 14995) +++ core/kernel/session/session.php (working copy) @@ -628,7 +628,7 @@ $this->SaveData(); } - $this->Application->resetCounters('UserSession'); + $this->Application->resetCounters('UserSessions'); return true; } Index: core/kernel/session/session_storage.php =================================================================== --- core/kernel/session/session_storage.php (revision 14995) +++ core/kernel/session/session_storage.php (working copy) @@ -340,9 +340,9 @@ if ($user_id != USER_GUEST) { // root & normal users $sql = 'SELECT VariableValue, VariableName - FROM '.TABLE_PREFIX.'PersistantSessionData + FROM '.TABLE_PREFIX.'UserPersistentSessionData WHERE PortalUserId = '.$user_id; - $this->PersistentVars = $this->Conn->GetCol($sql, 'VariableName'); + $this->PersistentVars = (array)$this->Conn->GetCol($sql, 'VariableName'); } else { $this->PersistentVars = Array (); @@ -372,7 +372,7 @@ $key_clause = 'PortalUserId = ' . $user_id . ' AND VariableName = ' . $this->Conn->qstr($var_name); $sql = 'SELECT VariableName - FROM ' . TABLE_PREFIX . 'PersistantSessionData + FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE ' . $key_clause; $record_found = $this->Conn->GetOne($sql); @@ -383,10 +383,10 @@ ); if ( $record_found ) { - $this->Conn->doUpdate($fields_hash, TABLE_PREFIX . 'PersistantSessionData', $key_clause); + $this->Conn->doUpdate($fields_hash, TABLE_PREFIX . 'UserPersistentSessionData', $key_clause); } else { - $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'PersistantSessionData'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'UserPersistentSessionData'); } } @@ -419,7 +419,7 @@ } $sql = 'SELECT VariableValue, VariableName - FROM ' . TABLE_PREFIX . 'PersistantSessionData + FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE VariableName = ' . $this->Conn->qstr($var_name) . ' AND PortalUserId = ' . $default_user_id; $value = $this->Conn->GetOne($sql); $this->PersistentVars[$var_name] = $value; @@ -452,7 +452,7 @@ $this->Session->RemoveVar($var_name); } else { - $sql = 'DELETE FROM ' . TABLE_PREFIX . 'PersistantSessionData + $sql = 'DELETE FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE PortalUserId = ' . $user_id . ' AND VariableName = ' . $this->Conn->qstr($var_name); $this->Conn->Query($sql); } Index: core/kernel/utility/debugger.php =================================================================== --- core/kernel/utility/debugger.php (revision 14988) +++ core/kernel/utility/debugger.php (working copy) @@ -838,7 +838,7 @@ { $sql = trim(preg_replace('/(\n|\t| )+/is', ' ', $sql)); - // whitespace in the beginning of the regex is to avoid splitting inside words, for exmaple "FROM int_ConfigurationValues" into "FROM intConfiguration\n\tValues" + // whitespace in the beginning of the regex is to avoid splitting inside words, for example "FROM int_ConfigurationValues" into "FROM intConfiguration\n\tValues" $formatted_sql = preg_replace('/\s(CREATE TABLE|DROP TABLE|SELECT|UPDATE|SET|REPLACE|INSERT|DELETE|VALUES|FROM|LEFT JOIN|INNER JOIN|LIMIT|WHERE|HAVING|GROUP BY|ORDER BY)\s/is', "\n\t$1 ", ' ' . $sql); $formatted_sql = $this->highlightString($formatted_sql); Index: core/kernel/utility/temp_handler.php =================================================================== --- core/kernel/utility/temp_handler.php (revision 14988) +++ core/kernel/utility/temp_handler.php (working copy) @@ -1018,8 +1018,8 @@ IF (s.PortalUserId = ' . USER_GUEST . ', \'Guest\', CONCAT(u.FirstName, \' \', u.LastName, \' (\', u.Username, \')\') ) - ), \' IP: \', s.IpAddress, \'\') FROM ' . TABLE_PREFIX . 'UserSession AS s - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser AS u + ), \' IP: \', s.IpAddress, \'\') FROM ' . TABLE_PREFIX . 'UserSessions AS s + LEFT JOIN ' . TABLE_PREFIX . 'Users AS u ON u.PortalUserId = s.PortalUserId WHERE s.SessionKey IN (' . implode(',', $sids) . ')'; $users = $this->Conn->GetCol($sql); Index: core/units/admin/admin_events_handler.php =================================================================== --- core/units/admin/admin_events_handler.php (revision 14989) +++ core/units/admin/admin_events_handler.php (working copy) @@ -463,7 +463,7 @@ } /** - * Refreshes ThemeFiles & Theme tables by actual content on HDD + * Refreshes ThemeFiles & Themes tables by actual content on HDD * * @param kEvent $event * @return void @@ -1082,7 +1082,7 @@ $start_time = adodb_mktime(); $sql = 'SELECT SessionKey - FROM ' . TABLE_PREFIX . 'UserSession + FROM ' . TABLE_PREFIX . 'UserSessions WHERE LastAccessed > ' . $start_time; $active_sessions = array_flip($this->Conn->GetCol($sql)); Index: core/units/ban_rules/ban_rules_config.php =================================================================== --- core/units/ban_rules/ban_rules_config.php (revision 14988) +++ core/units/ban_rules/ban_rules_config.php (working copy) @@ -32,7 +32,7 @@ 'IDField' => 'RuleId', - 'TableName' => TABLE_PREFIX.'BanRules', + 'TableName' => TABLE_PREFIX.'UserBanRules', 'StatusField' => Array ('Status'), Index: core/units/categories/cache_updater.php =================================================================== --- core/units/categories/cache_updater.php (revision 14988) +++ core/units/categories/cache_updater.php (working copy) @@ -227,7 +227,7 @@ $this->iteration = 0; $this->progressTable = $this->Application->GetTempName('permCacheUpdate'); - $this->permCacheTable = $this->Application->GetTempName(TABLE_PREFIX.'PermCache'); + $this->permCacheTable = $this->Application->GetTempName(TABLE_PREFIX.'CategoryPermissionsCache'); if (!isset($continuing) || $continuing == 1) { $this->InitUpdater(); @@ -285,13 +285,13 @@ $this->clearData(); // drop table before starting anyway // 1. create table for rebuilding permissions cache - $this->Conn->Query('CREATE TABLE '.$this->permCacheTable.' LIKE '.TABLE_PREFIX.'PermCache'); + $this->Conn->Query('CREATE TABLE '.$this->permCacheTable.' LIKE '.TABLE_PREFIX.'CategoryPermissionsCache'); if ($this->StrictPath) { // when using strict path leave all other cache intact $sql = 'INSERT INTO '.$this->permCacheTable.' SELECT * - FROM '.TABLE_PREFIX.'PermCache'; + FROM '.TABLE_PREFIX.'CategoryPermissionsCache'; $this->Conn->Query($sql); // delete only cache related to categories in path @@ -305,14 +305,17 @@ $this->Conn->Query('CREATE TABLE '.$this->progressTable.'(data LONGTEXT'.$add_charset.$add_collation.') '.$add_charset.$add_collation); - $this->totalCats = (int)$this->Conn->GetOne('SELECT COUNT(*) FROM '.TABLE_PREFIX.'Category'); + $this->totalCats = (int)$this->Conn->GetOne('SELECT COUNT(*) FROM '.TABLE_PREFIX.'Categories'); $this->doneCats = 0; } function clearData() { // some templates use this - $this->Conn->Query('UPDATE '.TABLE_PREFIX.'ConfigurationValues SET VariableValue = VariableValue+1 WHERE VariableName = \'CategoriesRebuildSerial\''); + $sql = 'UPDATE ' . TABLE_PREFIX . 'SystemSettings + SET VariableValue = VariableValue + 1 + WHERE VariableName = "CategoriesRebuildSerial"'; + $this->Conn->Query($sql); // always drop temporary tables $this->Conn->Query('DROP TABLE IF EXISTS '.$this->progressTable); @@ -323,9 +326,9 @@ function SaveData() { // copy data from temp permission cache table back to live - $this->Conn->Query('TRUNCATE '.TABLE_PREFIX.'PermCache'); + $this->Conn->Query('TRUNCATE '.TABLE_PREFIX.'CategoryPermissionsCache'); - $sql = 'INSERT INTO '.TABLE_PREFIX.'PermCache + $sql = 'INSERT INTO '.TABLE_PREFIX.'CategoryPermissionsCache SELECT * FROM '.$this->permCacheTable; $this->Conn->Query($sql); @@ -436,7 +439,7 @@ $fields_hash['l'.$language_id.'_CachedNavbar'] = implode('&|&', $data['titles'][$language_id]); } - $this->Conn->doUpdate($fields_hash, TABLE_PREFIX.'Category', 'CategoryId = '.$data['current_id']); + $this->Conn->doUpdate($fields_hash, TABLE_PREFIX.'Categories', 'CategoryId = '.$data['current_id']); if ($this->Conn->getAffectedRows() > 0) { $this->Application->incrementCacheSerial('c', $data['current_id']); @@ -447,7 +450,7 @@ { $category_id = $data['current_id']; $sql = 'SELECT * - FROM '.TABLE_PREFIX.'Category + FROM '.TABLE_PREFIX.'Categories WHERE CategoryId = '.$category_id; $record = $this->Conn->GetRow($sql); @@ -465,14 +468,14 @@ // it is one of the modules root category /*$root_prefix = isset($this->root_prefixes[$category_id]) ? $this->root_prefixes[$category_id] : false; - if ($root_prefix) { - $fields_hash = Array(); - if (!$record['Template']) { - $record['Template'] = $this->Application->ConfigValue($root_prefix.'_CategoryTemplate'); + if ( $root_prefix ) { + $fields_hash = Array (); + if ( !$record['Template'] ) { + $record['Template'] = $this->Application->ConfigValue($root_prefix . '_CategoryTemplate'); $fields_hash['Template'] = $record['Template']; } - $this->Conn->doUpdate($fields_hash, TABLE_PREFIX.'Category', 'CategoryId = '.$category_id); + $this->Conn->doUpdate($fields_hash, TABLE_PREFIX . 'Categories', 'CategoryId = ' . $category_id); }*/ // if explicitly set, then use it; use parent template otherwise @@ -486,7 +489,7 @@ function QueryChildren(&$data) { $sql = 'SELECT CategoryId - FROM '.TABLE_PREFIX.'Category + FROM '.TABLE_PREFIX.'Categories WHERE ParentId = '.$data['current_id']; $data['children'] = $this->Conn->GetCol($sql); } @@ -496,7 +499,7 @@ // don't search for section "view" permissions here :) $sql = 'SELECT ipc.PermissionConfigId, ip.GroupId, ip.PermissionValue FROM '.TABLE_PREFIX.'Permissions AS ip - LEFT JOIN '.TABLE_PREFIX.'PermissionConfig AS ipc ON ipc.PermissionName = ip.Permission + LEFT JOIN '.TABLE_PREFIX.'CategoryPermissionsConfig AS ipc ON ipc.PermissionName = ip.Permission WHERE (CatId = '.$data['current_id'].') AND (Permission LIKE "%.VIEW") AND (ip.Type = 0)'; $records = $this->Conn->Query($sql); Index: core/units/categories/categories_config.php =================================================================== --- core/units/categories/categories_config.php (revision 14988) +++ core/units/categories/categories_config.php (working copy) @@ -111,7 +111,8 @@ ), ), - 'TableName' => TABLE_PREFIX.'Category', + 'TableName' => TABLE_PREFIX.'Categories', + 'CustomDataTableName' => TABLE_PREFIX . 'CategoryCustomData', 'ViewMenuPhrase' => 'la_text_Categories', 'CatalogTabIcon' => 'icon16_sections.png', @@ -264,8 +265,8 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'%3$sImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1 - LEFT JOIN '.TABLE_PREFIX.'PermCache ON '.TABLE_PREFIX.'PermCache.CategoryId = %1$s.CategoryId + LEFT JOIN '.TABLE_PREFIX.'%3$sCatalogImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1 + LEFT JOIN '.TABLE_PREFIX.'CategoryPermissionsCache ON '.TABLE_PREFIX.'CategoryPermissionsCache.CategoryId = %1$s.CategoryId LEFT JOIN '.TABLE_PREFIX.'%3$sCategoryCustomData cust ON %1$s.ResourceId = cust.ResourceId', '-virtual' => 'SELECT %1$s.* %2$s FROM %1$s', ), @@ -326,7 +327,7 @@ 'MetaKeywords' => Array ('type' => 'string', 'formatter' => 'kFormatter', 'using_fck' => 1, 'default' => null), 'CachedDescendantCatsQty' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), 'CachedNavbar' => Array ('type' => 'string', 'formatter' => 'kMultiLanguage', 'default' => null), - 'CreatedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), + 'CreatedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'Users WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), 'ResourceId' => Array ('type' => 'int', 'default' => null), 'ParentPath' => Array ('type' => 'string', 'default' => null), 'TreeLeft' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), @@ -337,7 +338,7 @@ 'NewItem' => Array ('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Auto', 1 => 'la_Always', 0 => 'la_Never'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2), 'PopItem' => Array ('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Auto', 1 => 'la_Always', 0 => 'la_Never'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2), 'Modified' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => '#NOW#'), - 'ModifiedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), + 'ModifiedById' => Array ('type' => 'int', 'formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'Users WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), 'CachedTemplate' => Array ('type' => 'string', 'not_null' => 1, 'default' => ''), @@ -348,7 +349,7 @@ 'options_sql' => ' SELECT CONCAT(tf.Description, " :: ", FilePath, "/", TRIM(TRAILING ".tpl" FROM FileName) ) AS Title, IF(tf.TemplateAlias <> "", tf.TemplateAlias, CONCAT(FilePath, "/", TRIM(TRAILING ".tpl" FROM FileName))) AS Value FROM ' . TABLE_PREFIX . 'ThemeFiles AS tf - LEFT JOIN ' . TABLE_PREFIX . 'Theme AS t ON t.ThemeId = tf.ThemeId + LEFT JOIN ' . TABLE_PREFIX . 'Themes AS t ON t.ThemeId = tf.ThemeId WHERE (t.Enabled = 1) AND (tf.FileName NOT LIKE "%%.elm.tpl") AND (tf.FileName NOT LIKE "%%.des.tpl") AND (tf.FilePath = "/designs") ORDER BY tf.Description ASC, tf.FileName ASC', 'option_key_field' => 'Value', 'option_title_field' => 'Title', Index: core/units/categories/categories_event_handler.php =================================================================== --- core/units/categories/categories_event_handler.php (revision 14989) +++ core/units/categories/categories_event_handler.php (working copy) @@ -285,7 +285,7 @@ $recycle_bin = $this->Application->ConfigValue('RecycleBinFolder'); if ($recycle_bin) { $sql = 'SELECT TreeLeft, TreeRight - FROM '.TABLE_PREFIX.'Category + FROM '.TABLE_PREFIX.'Categories WHERE CategoryId = '.$recycle_bin; $tree_indexes = $this->Conn->GetRow($sql); @@ -322,7 +322,7 @@ // not "Home" category $tree_indexes = $this->Application->getTreeIndex($parent_cat_id); - $object->addFilter('parent_filter', TABLE_PREFIX.'Category.TreeLeft BETWEEN '.$tree_indexes['TreeLeft'].' AND '.$tree_indexes['TreeRight']); + $object->addFilter('parent_filter', '%1$s.TreeLeft BETWEEN '.$tree_indexes['TreeLeft'].' AND '.$tree_indexes['TreeRight']); } } else { @@ -330,14 +330,14 @@ } } - $object->addFilter('perm_filter', TABLE_PREFIX . 'PermCache.PermId = 1'); // check for CATEGORY.VIEW permission + $object->addFilter('perm_filter', TABLE_PREFIX . 'CategoryPermissionsCache.PermId = 1'); // check for CATEGORY.VIEW permission if ($this->Application->RecallVar('user_id') != USER_ROOT) { // apply permission filters to all users except "root" $view_filters = Array (); $groups = explode(',',$this->Application->RecallVar('UserGroups')); foreach ($groups as $group) { - $view_filters[] = 'FIND_IN_SET('.$group.', ' . TABLE_PREFIX . 'PermCache.ACL)'; + $view_filters[] = 'FIND_IN_SET('.$group.', ' . TABLE_PREFIX . 'CategoryPermissionsCache.ACL)'; } $view_filter = implode(' OR ', $view_filters); @@ -453,12 +453,12 @@ WHERE CategoryId = '.$parent_cat_id ); - $sql = 'SELECT DISTINCT(TargetId) FROM '.TABLE_PREFIX.'Relationship + $sql = 'SELECT DISTINCT(TargetId) FROM '.TABLE_PREFIX.'CatalogRelationships WHERE SourceId = '.$resource_id.' AND SourceType = 1'; $related_cats = $this->Conn->GetCol($sql); $related_cats = is_array($related_cats) ? $related_cats : Array(); - $sql = 'SELECT DISTINCT(SourceId) FROM '.TABLE_PREFIX.'Relationship + $sql = 'SELECT DISTINCT(SourceId) FROM '.TABLE_PREFIX.'CatalogRelationships WHERE TargetId = '.$resource_id.' AND TargetType = 1 AND Type = 1'; $related_cats2 = $this->Conn->GetCol($sql); $related_cats2 = is_array($related_cats2) ? $related_cats2 : Array(); @@ -485,11 +485,11 @@ WHERE ProductId = '.$product_id ); - $sql = 'SELECT DISTINCT(TargetId) FROM '.TABLE_PREFIX.'Relationship + $sql = 'SELECT DISTINCT(TargetId) FROM '.TABLE_PREFIX.'CatalogRelationships WHERE SourceId = '.$resource_id.' AND TargetType = 1'; $related_cats = $this->Conn->GetCol($sql); $related_cats = is_array($related_cats) ? $related_cats : Array(); - $sql = 'SELECT DISTINCT(SourceId) FROM '.TABLE_PREFIX.'Relationship + $sql = 'SELECT DISTINCT(SourceId) FROM '.TABLE_PREFIX.'CatalogRelationships WHERE TargetId = '.$resource_id.' AND SourceType = 1 AND Type = 1'; $related_cats2 = $this->Conn->GetCol($sql); $related_cats2 = is_array($related_cats2) ? $related_cats2 : Array(); @@ -1976,7 +1976,7 @@ parent::OnAfterConfigRead($event); if (defined('IS_INSTALL') && IS_INSTALL) { - // skip any processing, because Category table doesn't exists until install is finished + // skip any processing, because Categories table doesn't exists until install is finished return ; } @@ -2132,11 +2132,11 @@ { $sql = 'SELECT t.ThemeId, CONCAT( tf.FilePath, \'/\', tf.FileName ) AS Path, tf.FileMetaInfo FROM '.TABLE_PREFIX.'ThemeFiles AS tf - LEFT JOIN '.TABLE_PREFIX.'Theme AS t ON t.ThemeId = tf.ThemeId + LEFT JOIN '.TABLE_PREFIX.'Themes AS t ON t.ThemeId = tf.ThemeId WHERE t.Enabled = 1 AND tf.FileType = 1 AND ( SELECT COUNT(CategoryId) - FROM ' . TABLE_PREFIX . 'Category c + FROM ' . TABLE_PREFIX . 'Categories c WHERE CONCAT(\'/\', c.Template, \'.tpl\') = CONCAT( tf.FilePath, \'/\', tf.FileName ) AND (c.ThemeId = t.ThemeId) ) = 0 '; $files = $this->Conn->Query($sql, 'Path'); @@ -2507,13 +2507,13 @@ // don't save keywords for each module separately, just one time // static variable can't help here, because each module uses it's own class instance ! if (!$this->Application->GetVar('search_logged')) { - $sql = 'UPDATE '.TABLE_PREFIX.'SearchLog + $sql = 'UPDATE '.TABLE_PREFIX.'SearchLogs SET Indices = Indices + 1 WHERE Keyword = '.$this->Conn->qstr($keywords).' AND SearchType = '.$search_type; // 0 - simple search, 1 - advanced search $this->Conn->Query($sql); if ($this->Conn->getAffectedRows() == 0) { $fields_hash = Array('Keyword' => $keywords, 'Indices' => 1, 'SearchType' => $search_type); - $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'SearchLog'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'SearchLogs'); } $this->Application->SetVar('search_logged', 1); @@ -2641,7 +2641,7 @@ $language_name = $this->Application->getCache('language_names[%LangIDSerial:' . $processed_params['m_lang'] . '%]'); if ($language_name === false) { $sql = 'SELECT PackName - FROM ' . TABLE_PREFIX . 'Language + FROM ' . TABLE_PREFIX . 'Languages WHERE LanguageId = ' . $processed_params['m_lang']; $language_name = $this->Conn->GetOne($sql); @@ -2656,7 +2656,7 @@ $theme_name = $this->Application->getCache('theme_names[%ThemeIDSerial:' . $processed_params['m_theme'] . '%]'); if ($theme_name === false) { $sql = 'SELECT Name - FROM ' . TABLE_PREFIX . 'Theme + FROM ' . TABLE_PREFIX . 'Themes WHERE ThemeId = ' . $processed_params['m_theme']; $theme_name = $this->Conn->GetOne($sql); @@ -2743,7 +2743,7 @@ } $sql = 'SELECT CategoryId, NamedParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE FriendlyURL = ' . $this->Conn->qstr(implode('/', $url_parts)); $friendly = $this->Conn->GetRow($sql); @@ -2796,7 +2796,7 @@ } $sql = 'SELECT CategoryId, SymLinkCategoryId, NamedParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE (LOWER(NamedParentPath) = ' . $this->Conn->qstr($category_path) . ') AND (ThemeId = ' . $vars['m_theme'] . ' OR ThemeId = 0)'; $category_info = $this->Conn->GetRow($sql); @@ -2814,7 +2814,7 @@ // (used in case if url prior to symlink adding was indexed by spider or was bookmarked) if ($last_category_info['SymLinkCategoryId']) { $sql = 'SELECT CategoryId, NamedParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE (CategoryId = ' . $last_category_info['SymLinkCategoryId'] . ')'; $category_info = $this->Conn->GetRow($sql); Index: core/units/categories/categories_tag_processor.php =================================================================== --- core/units/categories/categories_tag_processor.php (revision 14988) +++ core/units/categories/categories_tag_processor.php (working copy) @@ -490,7 +490,7 @@ kUtil::safeDefine('CACHE_PERM_CHUNK_SIZE', 30); $continue = $this->Application->GetVar('continue'); - $total_cats = (int) $this->Conn->GetOne('SELECT COUNT(*) FROM '.TABLE_PREFIX.'Category'); + $total_cats = (int) $this->Conn->GetOne('SELECT COUNT(*) FROM '.TABLE_PREFIX.'Categories'); if ($continue === false && $total_cats > CACHE_PERM_CHUNK_SIZE) { // first step, if category count > CACHE_PERM_CHUNK_SIZE, then ask for cache update @@ -552,7 +552,7 @@ protected function SaveWarning($params) { if ( $this->Prefix == 'st' ) { - // don't use this method for other prefixes then Category, that use this tag processor + // don't use this method for other prefixes then Categories, that use this tag processor return parent::SaveWarning($params); } @@ -695,7 +695,7 @@ if ( !isset($current_path) ) { $sql = 'SELECT ParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId = ' . (int)$this->Application->GetVar('m_cat_id'); $current_path = $this->Conn->GetOne($sql); } @@ -704,11 +704,12 @@ $test_path = $params['parent_path']; } else { - $template = $params['template']; + $template = isset($params['template']) ? $params['template'] : ''; + if ( $template ) { // when using from "c:CachedMenu" tag $sql = 'SELECT ParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE NamedParentPath = ' . $this->Conn->qstr('Content/' . $template); $test_path = $this->Conn->GetOne($sql); } @@ -789,13 +790,13 @@ list ($tree_left, $tree_right) = $this->Application->getTreeIndex($category_id); $sql = 'SELECT MAX(Modified) AS ModDate, MAX(CreatedOn) AS NewDate - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE TreeLeft BETWEEN ' . $tree_left . ' AND ' . $tree_right; } else { // scan all categories in system $sql = 'SELECT MAX(Modified) AS ModDate, MAX(CreatedOn) AS NewDate - FROM ' . TABLE_PREFIX . 'Category'; + FROM ' . TABLE_PREFIX . 'Categories'; } $this->Conn->nextQueryCachable = true; @@ -1749,7 +1750,7 @@ function HasSubCats($params) { $sql = 'SELECT COUNT(*) - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE ParentId = ' . $params['cat_id']; return $this->Conn->GetOne($sql); Index: core/units/category_items/category_items_config.php =================================================================== --- core/units/category_items/category_items_config.php (revision 14988) +++ core/units/category_items/category_items_config.php (working copy) @@ -46,7 +46,7 @@ ), 'ListSQLs' => Array( ''=>' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'Category AS c ON c.CategoryId = %1$s.CategoryId', + LEFT JOIN '.TABLE_PREFIX.'Categories AS c ON c.CategoryId = %1$s.CategoryId', ), // key - special, value - list select sql 'ItemSQLs' => Array( ''=>'SELECT * FROM %s', ), Index: core/units/config_search/config_search_event_handler.php =================================================================== --- core/units/config_search/config_search_event_handler.php (revision 14989) +++ core/units/config_search/config_search_event_handler.php (working copy) @@ -133,7 +133,7 @@ $cf_search['Description'] = $custom_field->GetDBField('Prompt'); $cf_search['ConfigHeader'] = $custom_field->GetDBField('Heading'); // 'la_Text_CustomFields'; $cf_search['SimpleSearch'] = in_array($element_type, Array ('text', 'range', 'select', 'multiselect')) ? 1 : 0; - $cf_search['TableName'] = 'CustomField'; + $cf_search['TableName'] = 'CustomFields'; $sql = 'SELECT Module FROM ' . TABLE_PREFIX . 'ItemTypes Index: core/units/configuration/configuration_config.php =================================================================== --- core/units/configuration/configuration_config.php (revision 14988) +++ core/units/configuration/configuration_config.php (working copy) @@ -47,7 +47,7 @@ 'section_label' => Array ('prefixes' => Array ('conf_List'), 'format' => "#section_label#"), ), - 'TableName' => TABLE_PREFIX . 'ConfigurationValues', + 'TableName' => TABLE_PREFIX . 'SystemSettings', 'ListSQLs' => Array ( '' => 'SELECT %1$s.* %2$s FROM %1$s' Index: core/units/custom_data/custom_data_event_handler.php =================================================================== --- core/units/custom_data/custom_data_event_handler.php (revision 14988) +++ core/units/custom_data/custom_data_event_handler.php (working copy) @@ -26,9 +26,16 @@ { // 1. clone customdata table $clones = $this->Application->getUnitOption('cdata', 'Clones'); + + $data_table = $this->Application->getUnitOption($event->MasterEvent->Prefix, 'CustomDataTableName'); + + if ( !$data_table ) { + $data_table = $this->Application->getUnitOption($event->MasterEvent->Prefix, 'TableName') . 'CustomData'; + } + $clones[$event->MasterEvent->Prefix.'-cdata'] = Array ( 'ParentPrefix' => $event->MasterEvent->Prefix, - 'TableName' => $this->Application->getUnitOption($event->MasterEvent->Prefix, 'TableName').'CustomData', + 'TableName' => $data_table, ); $this->Application->setUnitOption('cdata', 'Clones', $clones); @@ -48,7 +55,7 @@ { static $custom_fields = Array (); - if (defined('IS_INSTALL') && IS_INSTALL && !$this->Application->TableFound('CustomField', true)) { + if (defined('IS_INSTALL') && IS_INSTALL && !$this->Application->TableFound('CustomFields', true)) { return false; } @@ -103,7 +110,7 @@ function getCustomFields() { $sql = 'SELECT * - FROM '.TABLE_PREFIX.'CustomField'; + FROM '.TABLE_PREFIX.'CustomFields'; $ret = $this->Conn->Query($sql, 'CustomFieldId'); ksort($ret); Index: core/units/custom_fields/custom_fields_config.php =================================================================== --- core/units/custom_fields/custom_fields_config.php (revision 14988) +++ core/units/custom_fields/custom_fields_config.php (working copy) @@ -67,7 +67,7 @@ ), ), - 'TableName' => TABLE_PREFIX.'CustomField', + 'TableName' => TABLE_PREFIX.'CustomFields', 'ListSQLs' => Array( ''=>'SELECT * FROM %s', ), // key - special, value - list select sql Index: core/units/email_events/email_events_config.php =================================================================== --- core/units/email_events/email_events_config.php (revision 14988) +++ core/units/email_events/email_events_config.php (working copy) @@ -87,7 +87,7 @@ ), ), - 'TableName' => TABLE_PREFIX . 'Events', + 'TableName' => TABLE_PREFIX . 'EmailEvents', 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s', Index: core/units/email_events/email_events_event_handler.php =================================================================== --- core/units/email_events/email_events_event_handler.php (revision 14989) +++ core/units/email_events/email_events_event_handler.php (working copy) @@ -271,7 +271,7 @@ case EmailEvent::ADDRESS_TYPE_USER: $sql = 'SELECT FirstName, LastName, Email, PortalUserId - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE Username = ' . $this->Conn->qstr($address); $user_info = $this->Conn->GetRow($sql); @@ -356,7 +356,7 @@ $language_field = $event->getEventParam('EmailEventType') == EmailEvent::EVENT_TYPE_FRONTEND ? 'FrontLanguage' : 'AdminLanguage'; $sql = 'SELECT FirstName, LastName, Email, ' . $language_field . ' AS Language - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE PortalUserId = ' . $to_user_id; $user_info = $this->Conn->GetRow($sql); @@ -433,7 +433,7 @@ case EmailEvent::ADDRESS_TYPE_USER: $sql = 'SELECT FirstName, LastName, Email - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE Username = ' . $this->Conn->qstr($address); $user_info = $this->Conn->GetRow($sql); @@ -450,9 +450,9 @@ case EmailEvent::ADDRESS_TYPE_GROUP: $sql = 'SELECT u.FirstName, u.LastName, u.Email - FROM ' . TABLE_PREFIX . 'PortalGroup g - JOIN ' . TABLE_PREFIX . 'UserGroup ug ON ug.GroupId = g.GroupId - JOIN ' . TABLE_PREFIX . 'PortalUser u ON u.PortalUserId = ug.PortalUserId + FROM ' . TABLE_PREFIX . 'UserGroups g + JOIN ' . TABLE_PREFIX . 'UserGroupRelations ug ON ug.GroupId = g.GroupId + JOIN ' . TABLE_PREFIX . 'Users u ON u.PortalUserId = ug.PortalUserId WHERE g.Name = ' . $this->Conn->qstr($address); $users = $this->Conn->Query($sql); @@ -1069,7 +1069,7 @@ case EmailEvent::ADDRESS_TYPE_USER: $sql = 'SELECT PortalUserId - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE Username = ' . $this->Conn->qstr($address); if (!$this->Conn->GetOne($sql)) { $object->SetError($field_prefix . 'Address', 'invalid_user'); @@ -1078,7 +1078,7 @@ case EmailEvent::ADDRESS_TYPE_GROUP: $sql = 'SELECT GroupId - FROM ' . TABLE_PREFIX . 'PortalGroup + FROM ' . TABLE_PREFIX . 'UserGroups WHERE Name = ' . $this->Conn->qstr($address); if (!$this->Conn->GetOne($sql)) { $object->SetError($field_prefix . 'Address', 'invalid_group'); @@ -1135,17 +1135,17 @@ switch ($address_type) { case EmailEvent::ADDRESS_TYPE_EMAIL: $field = 'Email'; - $table_name = TABLE_PREFIX . 'PortalUser'; + $table_name = TABLE_PREFIX . 'Users'; break; case EmailEvent::ADDRESS_TYPE_USER: $field = 'Username'; - $table_name = TABLE_PREFIX . 'PortalUser'; + $table_name = TABLE_PREFIX . 'Users'; break; case EmailEvent::ADDRESS_TYPE_GROUP: $field = 'Name'; - $table_name = TABLE_PREFIX . 'PortalGroup'; + $table_name = TABLE_PREFIX . 'UserGroups'; break; default: Index: core/units/favorites/favorites_config.php =================================================================== --- core/units/favorites/favorites_config.php (revision 14988) +++ core/units/favorites/favorites_config.php (working copy) @@ -44,7 +44,7 @@ ), 'IDField' => 'FavoriteId', - 'TableName' => TABLE_PREFIX.'Favorites', + 'TableName' => TABLE_PREFIX.'UserFavorites', 'ParentTableKey' => 'PortalUserId', 'ForeignKey' => 'PortalUserId', Index: core/units/fck/fck_eh.php =================================================================== --- core/units/fck/fck_eh.php (revision 14989) +++ core/units/fck/fck_eh.php (working copy) @@ -68,7 +68,7 @@ $page_ids = array_keys($pages); $sql = 'SELECT NamedParentPath, CategoryId - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId IN (' . implode(',', $page_ids) . ')'; $tpls = $this->Application->Conn->GetCol($sql, 'CategoryId'); Index: core/units/files/files_config.php =================================================================== --- core/units/files/files_config.php (revision 14988) +++ core/units/files/files_config.php (working copy) @@ -34,7 +34,7 @@ 'StatusField' => Array('Status'), 'TitleField' => 'FileName', - 'TableName' => TABLE_PREFIX.'ItemFiles', + 'TableName' => TABLE_PREFIX.'CatalogFiles', 'ParentTableKey' => 'ResourceId', 'ForeignKey' => 'ResourceId', Index: core/units/forms/drafts/drafts_config.php =================================================================== --- core/units/forms/drafts/drafts_config.php (revision 14988) +++ core/units/forms/drafts/drafts_config.php (working copy) @@ -38,7 +38,7 @@ 'AutoDelete' => true, 'AutoClone' => true, - 'TableName' => TABLE_PREFIX . 'Drafts', + 'TableName' => TABLE_PREFIX . 'FormSubmissionReplyDrafts', 'TitleField' => 'DraftId', Index: core/units/forms/submission_log/submission_log_config.php =================================================================== --- core/units/forms/submission_log/submission_log_config.php (revision 14988) +++ core/units/forms/submission_log/submission_log_config.php (working copy) @@ -32,7 +32,7 @@ 'IDField' => 'SubmissionLogId', - 'TableName' => TABLE_PREFIX . 'SubmissionLog', + 'TableName' => TABLE_PREFIX . 'FormSubmissionReplies', 'StatusField' => Array ('ReplyStatus'), Index: core/units/general/general_config.php =================================================================== --- core/units/general/general_config.php (revision 14988) +++ core/units/general/general_config.php (working copy) @@ -32,7 +32,7 @@ 'TitlePhrase' => 'la_Text_Category', 'CatalogTabIcon' => 'icon16_section.png', 'ItemType' => 1, - 'TableName' => TABLE_PREFIX . 'Category', + 'TableName' => TABLE_PREFIX . 'Categories', 'CatalogItem' => true, Index: core/units/groups/groups_config.php =================================================================== --- core/units/groups/groups_config.php (revision 14988) +++ core/units/groups/groups_config.php (working copy) @@ -86,7 +86,7 @@ 'PermSection' => Array ('main' => 'in-portal:user_groups'), - 'TableName' => TABLE_PREFIX.'PortalGroup', + 'TableName' => TABLE_PREFIX.'UserGroups', 'ListSQLs' => Array ( '' => 'SELECT %1$s.* %2$s FROM %1$s', @@ -100,7 +100,7 @@ 'CalculatedFields' => Array ( 'total' => Array ( - 'UserCount' => 'SELECT COUNT(*) FROM ' . TABLE_PREFIX . 'UserGroup ug WHERE ug.GroupId = %1$s.GroupId', + 'UserCount' => 'SELECT COUNT(*) FROM ' . TABLE_PREFIX . 'UserGroupRelations ug WHERE ug.GroupId = %1$s.GroupId', ), ), Index: core/units/groups/groups_event_handler.php =================================================================== --- core/units/groups/groups_event_handler.php (revision 14989) +++ core/units/groups/groups_event_handler.php (working copy) @@ -37,7 +37,7 @@ if ( $user_id !== false ) { // show only groups, that user doesn't belong to - $table_name = $this->Application->GetTempName(TABLE_PREFIX . 'UserGroup', 'prefix:u'); + $table_name = $this->Application->GetTempName(TABLE_PREFIX . 'UserGroupRelations', 'prefix:u'); $sql = 'SELECT GroupId FROM ' . $table_name . ' Index: core/units/helpers/ajax_form_helper.php =================================================================== --- core/units/helpers/ajax_form_helper.php (revision 14988) +++ core/units/helpers/ajax_form_helper.php (working copy) @@ -46,7 +46,7 @@ } /** - * Sends JSON-encoded responce as event result to the browser + * Sends JSON-encoded response as event result to the browser * * @param kEvent $event * @param Array $response Index: core/units/helpers/cat_dbitem_export_helper.php =================================================================== --- core/units/helpers/cat_dbitem_export_helper.php (revision 14988) +++ core/units/helpers/cat_dbitem_export_helper.php (working copy) @@ -497,7 +497,7 @@ } $join_clauses[TABLE_PREFIX . 'CategoryItems ci'] = 'ci.ItemResourceId = item_table.ResourceId'; - $join_clauses[TABLE_PREFIX . 'Category c'] = 'c.CategoryId = ci.CategoryId'; + $join_clauses[TABLE_PREFIX . 'Categories c'] = 'c.CategoryId = ci.CategoryId'; $sql = 'SELECT item_table.*, ci.CategoryId' . ($custom_sql ? ', ' . $custom_sql : '') . ' FROM ' . $this->curItem->TableName . ' item_table'; @@ -559,7 +559,7 @@ if ($this->exportOptions['IsBaseCategory'] ) { $sql = 'SELECT ParentPath - FROM '.TABLE_PREFIX.'Category + FROM '.TABLE_PREFIX.'Categories WHERE CategoryId = ' . (int)$this->Application->GetVar('m_cat_id'); $parent_path = $this->Conn->GetOne($sql); $parent_path = explode('|', substr($parent_path, 1, -1)); @@ -662,7 +662,7 @@ $current_category_id = $this->Application->GetVar('m_cat_id'); if ($current_category_id > 0) { - $sql = 'SELECT ParentPath FROM '.TABLE_PREFIX.'Category WHERE CategoryId = '.$current_category_id; + $sql = 'SELECT ParentPath FROM '.TABLE_PREFIX.'Categories WHERE CategoryId = '.$current_category_id; $this->exportOptions['ImportCategoryPath'] = $this->Conn->GetOne($sql); } else { @@ -825,7 +825,7 @@ // get category id from database by name $sql = 'SELECT CategoryId - FROM '.TABLE_PREFIX.'Category + FROM '.TABLE_PREFIX.'Categories WHERE ('.$lang_prefix.'Name = '.$this->Conn->qstr($category_name).') AND (ParentId = '.(int)$current_category_id.')'; $category_id = $this->Conn->GetOne($sql); @@ -928,7 +928,7 @@ FROM '.$this->curItem->TableName.' item_table LEFT JOIN '.$cdata_table.' custom_data ON custom_data.ResourceId = item_table.ResourceId LEFT JOIN '.TABLE_PREFIX.'CategoryItems ci ON ci.ItemResourceId = item_table.ResourceId - LEFT JOIN '.TABLE_PREFIX.'Category c ON c.CategoryId = ci.CategoryId + LEFT JOIN '.TABLE_PREFIX.'Categories c ON c.CategoryId = ci.CategoryId WHERE '.$where_clause; $item_id = $this->Conn->GetOne($sql); } @@ -995,7 +995,7 @@ $parent_path = $this->getFromCache('category_parent_path', $category_id); if ($parent_path === false) { $sql = 'SELECT ParentPath - FROM '.TABLE_PREFIX.'Category + FROM '.TABLE_PREFIX.'Categories WHERE CategoryId = '.$category_id; $parent_path = $this->Conn->GetOne($sql); $this->addToCache('category_parent_path', $category_id, $parent_path); @@ -1109,7 +1109,7 @@ /* @var $ml_formatter kMultiLanguage */ $sql = 'SELECT ' . $ml_formatter->LangFieldName('CachedNavbar') . ' - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId = ' . $category_id; $category_path = $this->Conn->GetOne($sql); @@ -1168,7 +1168,7 @@ $sql = 'SELECT IF(c.CategoryId IS NULL, 0, MAX( LENGTH(c.ParentPath) - LENGTH( REPLACE(c.ParentPath, "|", "") ) - 1 )) FROM '.$this->curItem->TableName.' item_table LEFT JOIN '.TABLE_PREFIX.'CategoryItems ci ON item_table.ResourceId = ci.ItemResourceId - LEFT JOIN '.TABLE_PREFIX.'Category c ON c.CategoryId = ci.CategoryId + LEFT JOIN '.TABLE_PREFIX.'Categories c ON c.CategoryId = ci.CategoryId WHERE (ci.PrimaryCat = 1) AND '; $where_clause = ''; Index: core/units/helpers/category_helper.php =================================================================== --- core/units/helpers/category_helper.php (revision 14988) +++ core/units/helpers/category_helper.php (working copy) @@ -516,12 +516,12 @@ LOWER( IF( c.SymLinkCategoryId IS NOT NULL, - (SELECT cc.NamedParentPath FROM ' . TABLE_PREFIX . 'Category AS cc WHERE cc.CategoryId = c.SymLinkCategoryId), + (SELECT cc.NamedParentPath FROM ' . TABLE_PREFIX . 'Categories AS cc WHERE cc.CategoryId = c.SymLinkCategoryId), c.NamedParentPath ) ) AS DstTemplate, c.UseExternalUrl, c.ExternalUrl - FROM ' . TABLE_PREFIX . 'Category AS c + FROM ' . TABLE_PREFIX . 'Categories AS c WHERE c.Status = ' . STATUS_ACTIVE; $pages = $this->Conn->Query($sql, 'SrcTemplate'); @@ -603,7 +603,7 @@ $page_ids = $regs[1]; $sql = 'SELECT NamedParentPath, CategoryId - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId IN (' . implode(',', $page_ids) . ')'; $templates = $this->Conn->GetCol($sql, 'CategoryId'); Index: core/units/helpers/count_helper.php =================================================================== --- core/units/helpers/count_helper.php (revision 14988) +++ core/units/helpers/count_helper.php (working copy) @@ -146,13 +146,13 @@ $sql = 'SELECT '.$count_sql.' FROM '.$table_name.' item_table INNER JOIN '.TABLE_PREFIX.'CategoryItems ci ON (ci.ItemResourceId = item_table.ResourceId) - INNER JOIN '.TABLE_PREFIX.'Category c ON (ci.CategoryId = c.CategoryId)'; + INNER JOIN '.TABLE_PREFIX.'Categories c ON (ci.CategoryId = c.CategoryId)'; // 2. count items from subcategories if ($category_id > 0) { // get subcategories of required category $tmp_sql = 'SELECT TreeLeft, TreeRight - FROM '.TABLE_PREFIX.'Category + FROM '.TABLE_PREFIX.'Categories WHERE CategoryId = '.$category_id; $tree_info = $this->Conn->GetRow($tmp_sql); $where_clauses[] = 'c.TreeLeft BETWEEN '.$tree_info['TreeLeft'].' AND '.$tree_info['TreeRight']; @@ -188,8 +188,8 @@ $sql = 'SELECT '.$count_sql.' FROM '.$table_name.' item_table INNER JOIN '.TABLE_PREFIX.'CategoryItems ci ON ci.ItemResourceId = item_table.ResourceId - INNER JOIN '.TABLE_PREFIX.'Category c ON c.CategoryId = ci.CategoryId - INNER JOIN '.TABLE_PREFIX.'PermCache perm_cache ON ci.CategoryId = perm_cache.CategoryId'; + INNER JOIN '.TABLE_PREFIX.'Categories c ON c.CategoryId = ci.CategoryId + INNER JOIN '.TABLE_PREFIX.'CategoryPermissionsCache perm_cache ON ci.CategoryId = perm_cache.CategoryId'; list ($view_perm, $view_filter) = $this->GetPermissionClause($prefix, 'perm_cache'); $where_clauses = Array ( @@ -226,7 +226,7 @@ if ($count === false) { $sql = 'SELECT COUNT(*) FROM ' . $this->Application->getUnitOption('c', 'TableName') . ' c - INNER JOIN ' . TABLE_PREFIX . 'PermCache perm_cache ON c.CategoryId = perm_cache.CategoryId'; + INNER JOIN ' . TABLE_PREFIX . 'CategoryPermissionsCache perm_cache ON c.CategoryId = perm_cache.CategoryId'; list ($view_perm, $view_filter) = $this->GetPermissionClause('c', 'perm_cache'); @@ -267,7 +267,7 @@ $this->Conn->nextQueryCachable = true; $sql = 'SELECT PermissionConfigId, PermissionName - FROM '.TABLE_PREFIX.'PermissionConfig + FROM '.TABLE_PREFIX.'CategoryPermissionsConfig WHERE PermissionName LIKE "%.VIEW"'; $permissions_ids = $this->Conn->GetCol($sql, 'PermissionName'); Index: core/units/helpers/file_helper.php =================================================================== --- core/units/helpers/file_helper.php (revision 14988) +++ core/units/helpers/file_helper.php (working copy) @@ -28,7 +28,7 @@ $max_file_count = $this->Application->ConfigValue($object->Prefix.'_MaxImageCount'); // file count equals to image count (temporary measure) $sql = 'SELECT * - FROM '.TABLE_PREFIX.'ItemFiles + FROM '.TABLE_PREFIX.'CatalogFiles WHERE ResourceId = '.$object->GetDBField('ResourceId').' ORDER BY FileId ASC LIMIT 0, '.(int)$max_file_count; Index: core/units/helpers/image_helper.php =================================================================== --- core/units/helpers/image_helper.php (revision 14988) +++ core/units/helpers/image_helper.php (working copy) @@ -560,7 +560,7 @@ $max_image_count = $this->Application->ConfigValue($object->Prefix.'_MaxImageCount'); $sql = 'SELECT * - FROM '.TABLE_PREFIX.'Images + FROM '.TABLE_PREFIX.'CatalogImages WHERE ResourceId = '.$object->GetDBField('ResourceId').' ORDER BY Priority DESC LIMIT 0, ' . (int)$max_image_count; Index: core/units/helpers/language_import_helper.php =================================================================== --- core/units/helpers/language_import_helper.php (revision 14988) +++ core/units/helpers/language_import_helper.php (working copy) @@ -671,7 +671,7 @@ function _updateEventsCache() { $sql = 'SELECT EventId, CONCAT(Event,"_",Type) AS EventMix - FROM ' . TABLE_PREFIX . 'Events'; + FROM ' . TABLE_PREFIX . 'EmailEvents'; $this->events_hash = $this->Conn->GetCol($sql, 'EventMix'); } Index: core/units/helpers/mailing_list_helper.php =================================================================== --- core/units/helpers/mailing_list_helper.php (revision 14988) +++ core/units/helpers/mailing_list_helper.php (working copy) @@ -172,14 +172,14 @@ switch ($recipient_type) { case 'u': $sql = 'SELECT Email - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE (PortalUserId IN (' . implode(',', $recipient_ids) . ')) AND (Email <> "")'; break; case 'g': $sql = 'SELECT u.Email - FROM ' . TABLE_PREFIX . 'UserGroup ug - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser u ON u.PortalUserId = ug.PortalUserId + FROM ' . TABLE_PREFIX . 'UserGroupRelations ug + LEFT JOIN ' . TABLE_PREFIX . 'Users u ON u.PortalUserId = ug.PortalUserId WHERE (ug.GroupId IN (' . implode(',', $recipient_ids) . ')) AND (u.Email <> "")'; break; Index: core/units/helpers/menu_helper.php =================================================================== --- core/units/helpers/menu_helper.php (revision 14988) +++ core/units/helpers/menu_helper.php (working copy) @@ -120,7 +120,7 @@ if ($root_path === false) { $this->Conn->nextQueryCachable = true; $sql = 'SELECT ParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId = ' . $root_cat; $root_path = $this->Conn->GetOne($sql); $this->Application->setCache($cache_key, $root_path); @@ -359,7 +359,7 @@ \'cat\' AS ItemType, c.IsMenu, c.Type, c.ThemeId, c.UseExternalUrl, c.ExternalUrl, c.UseMenuIconUrl, c.MenuIconUrl, c.Status - FROM ' . TABLE_PREFIX . 'Category AS c'; + FROM ' . TABLE_PREFIX . 'Categories AS c'; $items = $this->Conn->Query($sql, 'ItemId'); foreach ($items as $item_id => $item_data) { Index: core/units/helpers/mod_rewrite_helper.php =================================================================== --- core/units/helpers/mod_rewrite_helper.php (revision 14988) +++ core/units/helpers/mod_rewrite_helper.php (working copy) @@ -265,7 +265,7 @@ // locating the item in CategoryItems by filename to detect its ItemPrefix and its category ParentPath $sql = 'SELECT ci.ItemResourceId, ci.ItemPrefix, c.ParentPath, ci.CategoryId FROM ' . TABLE_PREFIX . 'CategoryItems AS ci - LEFT JOIN ' . TABLE_PREFIX . 'Category AS c ON c.CategoryId = ci.CategoryId + LEFT JOIN ' . TABLE_PREFIX . 'Categories AS c ON c.CategoryId = ci.CategoryId WHERE (ci.CategoryId = ' . (int)$vars['m_cat_id'] . ') AND (ci.Filename = ' . $this->Conn->qstr($item_filename) . ')'; $cat_item = $this->Conn->GetRow($sql); @@ -315,7 +315,7 @@ /* @var $rewrite_processor kRewriteUrlProcessor */ $sql = 'SELECT c.ParentPath, c.CategoryId - FROM ' . TABLE_PREFIX . 'Category AS c + FROM ' . TABLE_PREFIX . 'Categories AS c WHERE c.CategoryId = ' . (int)$vars['m_cat_id']; $cat_item = $this->Conn->GetRow($sql); Index: core/units/helpers/page_helper.php =================================================================== --- core/units/helpers/page_helper.php (revision 14988) +++ core/units/helpers/page_helper.php (working copy) @@ -34,7 +34,7 @@ $sql = 'SELECT CASE pr.CreatedById WHEN ' . USER_ROOT . ' THEN "root" WHEN ' . USER_GUEST . ' THEN "Guest" ELSE u.Username END FROM ' . $this->Application->getUnitOption('page-revision', 'TableName') . ' pr - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser u ON u.PortalUserId = pr.CreatedById + LEFT JOIN ' . TABLE_PREFIX . 'Users u ON u.PortalUserId = pr.CreatedById WHERE (' . implode(') AND (', $where_clause) . ')'; $users = $this->Conn->GetCol($sql); Index: core/units/helpers/permissions_helper.php =================================================================== --- core/units/helpers/permissions_helper.php (revision 14989) +++ core/units/helpers/permissions_helper.php (working copy) @@ -606,7 +606,7 @@ if ( $groups === false ) { // die('me'); $sql = 'SELECT GroupId - FROM '.TABLE_PREFIX.'UserGroup + FROM '.TABLE_PREFIX.'UserGroupRelations WHERE (PortalUserId = '.$user_id.') AND ( (MembershipExpires IS NULL) OR ( MembershipExpires >= UNIX_TIMESTAMP() ) )'; $groups = $this->Conn->GetCol($sql); @@ -633,12 +633,12 @@ } $sql = 'SELECT PermissionConfigId - FROM ' . TABLE_PREFIX . 'PermissionConfig + FROM ' . TABLE_PREFIX . 'CategoryPermissionsConfig WHERE PermissionName = ' . $this->Conn->qstr($name); $perm_id = $this->Conn->GetOne($sql); $sql = 'SELECT PermId - FROM ' . TABLE_PREFIX . 'PermCache + FROM ' . TABLE_PREFIX . 'CategoryPermissionsCache WHERE (PermId = ' . $perm_id . ') AND (CategoryId = ' . (int)$cat_id . ')'; $view_filters = Array (); @@ -714,7 +714,7 @@ // get all categories along with their parent path $sql = 'SELECT ParentPath, CategoryId - FROM ' . TABLE_PREFIX . 'Category'; + FROM ' . TABLE_PREFIX . 'Categories'; $parent_paths = $this->Conn->GetCol($sql, 'CategoryId'); foreach ($parent_paths as $category_id => $parent_path) { Index: core/units/helpers/rating_helper.php =================================================================== --- core/units/helpers/rating_helper.php (revision 14988) +++ core/units/helpers/rating_helper.php (working copy) @@ -194,7 +194,7 @@ 'IPAddress' => $_SERVER['REMOTE_ADDR'], 'CreatedOn' => adodb_mktime(), ); - $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'ItemRating'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX.'CatalogRatings'); // recalculate average rating $votes_count = $object->GetDBField('CachedVotesQty'); @@ -221,7 +221,7 @@ { $expired = adodb_mktime() - 86400 * $this->Application->ConfigValue('Timeout_Rating'); // 3600 - $sql = 'DELETE FROM ' . TABLE_PREFIX . 'ItemRating + $sql = 'DELETE FROM ' . TABLE_PREFIX . 'CatalogRatings WHERE CreatedOn < ' . $expired; $this->Conn->Query($sql); }*/ Index: core/units/helpers/recursive_helper.php =================================================================== --- core/units/helpers/recursive_helper.php (revision 14988) +++ core/units/helpers/recursive_helper.php (working copy) @@ -40,7 +40,7 @@ $temp_handler =& $this->Application->recallObject($prefix.'_TempHandler', 'kTempTablesHandler'); /* @var $temp_handler kTempTablesHandler */ - + // 2. delete items this have this category as primary $delete_ids = $this->getCategoryItems($category_id, true); @@ -217,7 +217,7 @@ if (!array_key_exists($category_id, $cache)) { $sql = 'SELECT ParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId = ' . $category_id; $cache[$category_id] = $this->Conn->GetOne($sql); } Index: core/units/helpers/skin_helper.php =================================================================== --- core/units/helpers/skin_helper.php (revision 14988) +++ core/units/helpers/skin_helper.php (working copy) @@ -123,7 +123,7 @@ if ($ret === false) { $this->Conn->nextQueryCachable = true; $sql = 'SELECT * - FROM ' . TABLE_PREFIX . 'Skins + FROM ' . TABLE_PREFIX . 'AdminSkins WHERE IsPrimary = 1'; $ret = $this->Conn->GetRow($sql); Index: core/units/helpers/themes_helper.php =================================================================== --- core/units/helpers/themes_helper.php (revision 14988) +++ core/units/helpers/themes_helper.php (working copy) @@ -305,7 +305,7 @@ function synchronizeModule($module_name) { $sql = 'SELECT `Name`, ThemeId - FROM ' . TABLE_PREFIX . 'Theme'; + FROM ' . TABLE_PREFIX . 'Themes'; $themes = $this->Conn->GetCol($sql, 'ThemeId'); if (!$themes) { @@ -323,12 +323,12 @@ 'TemplateAliases' => serialize( $this->getTemplateAliases($theme_id, $theme_path) ), ); - $this->Conn->doUpdate($fields_hash, TABLE_PREFIX . 'Theme', 'ThemeId = ' . $theme_id); + $this->Conn->doUpdate($fields_hash, TABLE_PREFIX . 'Themes', 'ThemeId = ' . $theme_id); } } /** - * Searches for new templates (missing in db) in spefied folder + * Searches for new templates (missing in db) in specified folder * * @param string $folder_path subfolder of searchable theme * @param string $theme_path theme path from web server root Index: core/units/helpers/user_helper.php =================================================================== --- core/units/helpers/user_helper.php (revision 14994) +++ core/units/helpers/user_helper.php (working copy) @@ -79,7 +79,7 @@ } // reset counters - $this->Application->resetCounters('UserSession'); + $this->Application->resetCounters('UserSessions'); $this->_processLoginRedirect('root', $password); $this->_processInterfaceLanguage(); @@ -112,7 +112,7 @@ if (!$remember_login_cookie) { // reset counters - $this->Application->resetCounters('UserSession'); + $this->Application->resetCounters('UserSessions'); $this->_processLoginRedirect($username, $password); $this->_processInterfaceLanguage(); @@ -253,7 +253,7 @@ if ( !isset($cache) ) { $sql = 'SELECT IPRestrictions, GroupId - FROM ' . TABLE_PREFIX . 'PortalGroup + FROM ' . TABLE_PREFIX . 'UserGroups WHERE IPRestrictions IS NOT NULL'; $cache = $this->Conn->GetCol($sql, 'GroupId'); } @@ -299,7 +299,7 @@ $this->event->SetRedirectParam('js_redirect', 1); } - $this->Application->resetCounters('UserSession'); + $this->Application->resetCounters('UserSessions'); $this->Application->Session->SetCookie('remember_login', '', strtotime('-1 hour')); // don't pass user prefix on logout, since resulting url will have broken "env" @@ -323,7 +323,7 @@ } $sql = 'SELECT PortalUserId - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE (Email = %1$s OR Username = %1$s) AND (Password = %2$s)'; return $this->Conn->GetOne( sprintf($sql, $this->Conn->qstr($username), $this->Conn->qstr($password) ) ); } @@ -372,7 +372,7 @@ $user_language_id = $is_root ? $this->Application->RecallPersistentVar($language_field) : $object->GetDBField($language_field); $sql = 'SELECT LanguageId, IF(LanguageId = ' . (int)$user_language_id . ', 2, ' . $primary_language_field . ') AS SortKey - FROM ' . TABLE_PREFIX . 'Language + FROM ' . TABLE_PREFIX . 'Languages WHERE Enabled = 1 HAVING SortKey <> 0 ORDER BY SortKey DESC'; @@ -532,7 +532,7 @@ } $sql = 'SELECT PwRequestTime, PortalUserId - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE PwResetConfirm = ' . $this->Conn->qstr( trim($user_code) ); $user_info = $this->Conn->GetRow($sql); @@ -567,7 +567,7 @@ } $sql = 'SELECT PortalUserId, PrevEmails - FROM ' . TABLE_PREFIX . 'PortalUser + FROM ' . TABLE_PREFIX . 'Users WHERE PrevEmails LIKE ' . $this->Conn->qstr('%' . $hash . '%'); $user_info = $this->Conn->GetRow($sql); Index: core/units/images/image_event_handler.php =================================================================== --- core/units/images/image_event_handler.php (revision 14989) +++ core/units/images/image_event_handler.php (working copy) @@ -437,7 +437,7 @@ function _getPendingImages() { $tables = $this->Conn->GetCol('SHOW TABLES'); - $mask_edit_table = '/'.TABLE_PREFIX.'ses_(.*)_edit_' . TABLE_PREFIX . 'Images/'; + $mask_edit_table = '/'.TABLE_PREFIX.'ses_(.*)_edit_' . TABLE_PREFIX . 'CatalogImages/'; $active_images = Array (); @@ -464,7 +464,7 @@ if ($images) { $images = array_map('basename', $images); - // delete images, that are on disk, but are not mentioned in Images table + // delete images, that are on disk, but are not mentioned in CatalogImages table $delete_images = array_diff($images, $active_images); foreach ($delete_images as $delete_image) { unlink($path . $delete_image); Index: core/units/images/images_config.php =================================================================== --- core/units/images/images_config.php (revision 14988) +++ core/units/images/images_config.php (working copy) @@ -77,7 +77,7 @@ 'IDField' => 'ImageId', 'StatusField' => Array('Enabled', 'DefaultImg'), // field, that is affected by Approve/Decline events 'TitleField' => 'Name', // field, used in bluebar when editing existing item - 'TableName' => TABLE_PREFIX.'Images', + 'TableName' => TABLE_PREFIX.'CatalogImages', 'ParentTableKey'=> 'ResourceId', // linked field in master table 'ForeignKey' => 'ResourceId', // linked field in subtable 'ParentPrefix' => 'p', Index: core/units/languages/languages_config.php =================================================================== --- core/units/languages/languages_config.php (revision 14988) +++ core/units/languages/languages_config.php (working copy) @@ -130,7 +130,7 @@ ),*/ ), - 'TableName' => TABLE_PREFIX . 'Language', + 'TableName' => TABLE_PREFIX . 'Languages', 'AutoDelete' => true, 'AutoClone' => true, @@ -148,12 +148,12 @@ 'LanguageId' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), 'PackName' => Array ( 'type' => 'string', - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Language ORDER BY PackName', 'option_title_field' => 'PackName', 'option_key_field' => 'PackName', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Languages ORDER BY PackName', 'option_title_field' => 'PackName', 'option_key_field' => 'PackName', 'not_null' => 1, 'required' => 1, 'default' => '' ), 'LocalName' => Array ( 'type' => 'string', - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Language ORDER BY PackName', 'option_title_field' => 'LocalName', 'option_key_field' => 'LocalName', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Languages ORDER BY PackName', 'option_title_field' => 'LocalName', 'option_key_field' => 'LocalName', 'not_null' => 1, 'required' => 1, 'default' => '' ), 'Enabled' => Array ( @@ -218,7 +218,7 @@ 'CopyLabels' => Array ('type' => 'int', 'default' => 0), 'CopyFromLanguage' => Array ( 'type' => 'int', - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Language ORDER BY PackName', 'option_title_field' => 'PackName', 'option_key_field' => 'LanguageId', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Languages ORDER BY PackName', 'option_title_field' => 'PackName', 'option_key_field' => 'LanguageId', 'default' => '', ), ), Index: core/units/languages/languages_event_handler.php =================================================================== --- core/units/languages/languages_event_handler.php (revision 14989) +++ core/units/languages/languages_event_handler.php (working copy) @@ -600,7 +600,7 @@ $object =& $event->getObject(); /* @var $object kDBItem */ - // clean Events table + // clean EmailEvents table $fields_hash = Array ( 'l' . $object->GetID() . '_Subject' => NULL, 'l' . $object->GetID() . '_Body' => NULL, @@ -632,7 +632,7 @@ // get language list with primary language first $sql = 'SELECT SynchronizationModes, LanguageId - FROM ' . TABLE_PREFIX . 'Language + FROM ' . TABLE_PREFIX . 'Languages WHERE SynchronizationModes <> "" ORDER BY PrimaryLang DESC'; $languages = $this->Conn->GetCol($sql, 'LanguageId'); @@ -655,7 +655,7 @@ continue; } - $sql = 'UPDATE ' . TABLE_PREFIX . 'Phrase + $sql = 'UPDATE ' . TABLE_PREFIX . 'LanguageLabels SET l' . $target_id . '_Translation = l' . $source_id . '_Translation WHERE COALESCE(l' . $target_id . '_Translation, "") = "" AND COALESCE(l' . $source_id . '_Translation, "") <> ""'; $this->Conn->Query($sql); Index: core/units/languages/languages_item.php =================================================================== --- core/units/languages/languages_item.php (revision 14988) +++ core/units/languages/languages_item.php (working copy) @@ -153,7 +153,7 @@ if ($available_languages === false) { $this->Conn->nextQueryCachable = true; $sql = 'SELECT LanguageId, LOWER(Locale) AS Locale - FROM ' . TABLE_PREFIX . 'Language + FROM ' . TABLE_PREFIX . 'Languages WHERE Enabled = 1'; $available_languages = $this->Conn->GetCol($sql, 'Locale'); $this->Application->setCache($cache_key, $available_languages); Index: core/units/logs/change_logs/change_logs_config.php =================================================================== --- core/units/logs/change_logs/change_logs_config.php (revision 14988) +++ core/units/logs/change_logs/change_logs_config.php (working copy) @@ -77,7 +77,7 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalUser AS u ON u.PortalUserId = %1$s.PortalUserId', + LEFT JOIN '.TABLE_PREFIX.'Users AS u ON u.PortalUserId = %1$s.PortalUserId', ), 'ListSortings' => Array ( Index: core/units/logs/search_logs/search_logs_config.php =================================================================== --- core/units/logs/search_logs/search_logs_config.php (revision 14988) +++ core/units/logs/search_logs/search_logs_config.php (working copy) @@ -33,7 +33,7 @@ 'IDField' => 'SearchLogId', - 'TableName' => TABLE_PREFIX . 'SearchLog', + 'TableName' => TABLE_PREFIX . 'SearchLogs', 'TitlePresets' => Array ( 'search_log_list' => Array ( Index: core/units/logs/session_logs/session_logs_config.php =================================================================== --- core/units/logs/session_logs/session_logs_config.php (revision 14988) +++ core/units/logs/session_logs/session_logs_config.php (working copy) @@ -58,7 +58,7 @@ 'IDField' => 'SessionLogId', 'StatusField' => Array ('Status'), - 'TableName' => TABLE_PREFIX.'SessionLogs', + 'TableName' => TABLE_PREFIX.'UserSessionLogs', 'TitlePresets' => Array ( 'session_log_list' => Array ('prefixes' => Array('session-log_List'), 'format' => '!la_tab_SessionLogs!', @@ -88,7 +88,7 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalUser AS u ON u.PortalUserId = %1$s.PortalUserId', + LEFT JOIN '.TABLE_PREFIX.'Users AS u ON u.PortalUserId = %1$s.PortalUserId', ), 'ListSortings' => Array ( Index: core/units/mailing_lists/mailing_lists_config.php =================================================================== --- core/units/mailing_lists/mailing_lists_config.php (revision 14988) +++ core/units/mailing_lists/mailing_lists_config.php (working copy) @@ -98,7 +98,7 @@ 'type' => 'int', 'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root'), - 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', + 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Users WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'required' => 1, 'not_null' => 1, 'default' => USER_ROOT, ), Index: core/units/page_revisions/page_revisions_config.php =================================================================== --- core/units/page_revisions/page_revisions_config.php (revision 14988) +++ core/units/page_revisions/page_revisions_config.php (working copy) @@ -43,8 +43,8 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - JOIN ' . TABLE_PREFIX . '%3$sCategory c ON c.CategoryId = %1$s.PageId - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser created_by ON created_by.PortalUserId = %1$s.CreatedById' + JOIN ' . TABLE_PREFIX . '%3$sCategories c ON c.CategoryId = %1$s.PageId + LEFT JOIN ' . TABLE_PREFIX . 'Users created_by ON created_by.PortalUserId = %1$s.CreatedById' ), 'SubItems' => Array ('content'), @@ -74,7 +74,7 @@ 'FromRevisionId' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), 'CreatedById' => Array ( 'type' => 'int', - 'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'), 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'sample_value' => 'Guest', 'required' => 1, + 'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'), 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Users WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'sample_value' => 'Guest', 'required' => 1, 'default' => NULL ), 'CreatedOn' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => '#NOW#'), Index: core/units/permission_types/permission_types_config.php =================================================================== --- core/units/permission_types/permission_types_config.php (revision 14988) +++ core/units/permission_types/permission_types_config.php (working copy) @@ -32,7 +32,7 @@ 'IDField' => 'PermissionConfigId', - 'TableName' => TABLE_PREFIX . 'PermissionConfig', + 'TableName' => TABLE_PREFIX . 'CategoryPermissionsConfig', 'TitleField' => 'PermissionName', Index: core/units/permissions/permissions_tag_processor.php =================================================================== --- core/units/permissions/permissions_tag_processor.php (revision 14988) +++ core/units/permissions/permissions_tag_processor.php (working copy) @@ -64,7 +64,7 @@ $permissions_helper =& $this->Application->recallObject('PermissionsHelper'); /* @var $permissions_helper kPermissionsHelper */ - + if (!$permissions_helper->isOldPermission($section_name, $perm_name)) { $perm_name = $section_name.'.'.$perm_name; } @@ -120,7 +120,7 @@ $sql = 'SELECT '.$case.', p.Permission AS Perm FROM '.$perm_live_table.' p - LEFT JOIN '.TABLE_PREFIX.'PermissionConfig pc ON pc.PermissionName = p.Permission + LEFT JOIN '.TABLE_PREFIX.'CategoryPermissionsConfig pc ON pc.PermissionName = p.Permission WHERE p.CatId IN ('.implode(',', $categories).') AND pc.ModuleId = ' . $this->Conn->qstr($module) . ' AND @@ -146,7 +146,7 @@ IF (tmp_p.CatId IS NOT NULL, tmp_p.CatId, IF(p.CatId IS NOT NULL, p.CatId, 0) ) AS InheritedFrom, IF(tmp_p.CatId = '.$category->GetID().', 0, 1) AS Inherited, IF(p.PermissionValue IS NOT NULL, p.PermissionValue, 0) AS InheritedValue - FROM '.TABLE_PREFIX.'PermissionConfig pc + FROM '.TABLE_PREFIX.'CategoryPermissionsConfig pc LEFT JOIN '.$perm_live_table.' p ON (p.Permission = pc.PermissionName) AND ('.str_replace('#TABLE_PREFIX#', 'p', $pos_sql).') AND (p.GroupId = '.(int)$group_id.') LEFT JOIN '.$perm_temp_table.' tmp_p Index: core/units/phrases/phrases_config.php =================================================================== --- core/units/phrases/phrases_config.php (revision 14988) +++ core/units/phrases/phrases_config.php (working copy) @@ -86,7 +86,7 @@ ) ), - 'TableName' => TABLE_PREFIX . 'Phrase', + 'TableName' => TABLE_PREFIX . 'LanguageLabels', 'CalculatedFields' => Array ( '' => Array ( Index: core/units/promo_block_groups/promo_block_group_eh.php =================================================================== --- core/units/promo_block_groups/promo_block_group_eh.php (revision 14988) +++ core/units/promo_block_groups/promo_block_group_eh.php (working copy) @@ -91,7 +91,7 @@ { parent::OnAfterItemDelete($event); - $sql = 'UPDATE ' . TABLE_PREFIX . 'Category + $sql = 'UPDATE ' . TABLE_PREFIX . 'Categories SET PromoBlockGroupId = 0 WHERE PromoBlockGroupId = ' . $event->getEventParam('id'); $this->Conn->Query($sql); Index: core/units/promo_block_groups/promo_block_groups_config.php =================================================================== --- core/units/promo_block_groups/promo_block_groups_config.php (revision 14988) +++ core/units/promo_block_groups/promo_block_groups_config.php (working copy) @@ -52,7 +52,7 @@ 'CalculatedFields' => Array ( '' => Array ( - 'AssignedToSections' => '(SELECT GROUP_CONCAT(CategoryId SEPARATOR ";") FROM '.TABLE_PREFIX.'Category WHERE PromoBlockGroupId = %1$s.PromoBlockGroupId)', + 'AssignedToSections' => '(SELECT GROUP_CONCAT(CategoryId SEPARATOR ";") FROM '.TABLE_PREFIX.'Categories WHERE PromoBlockGroupId = %1$s.PromoBlockGroupId)', ), ), Index: core/units/promo_blocks/promo_block_eh.php =================================================================== --- core/units/promo_blocks/promo_block_eh.php (revision 14989) +++ core/units/promo_blocks/promo_block_eh.php (working copy) @@ -236,7 +236,7 @@ if ( $object->GetDBField('LinkType') == 1 ) { // Internal $sql = 'SELECT NamedParentPath - FROM ' . TABLE_PREFIX . 'Category + FROM ' . TABLE_PREFIX . 'Categories WHERE CategoryId = ' . $object->GetDBField('CategoryId'); $event->redirect = $this->Conn->GetOne($sql); @@ -337,7 +337,7 @@ // get active languages $sql = 'SELECT LanguageId - FROM ' . TABLE_PREFIX . 'Language'; + FROM ' . TABLE_PREFIX . 'Languages'; $languages = $this->Conn->GetCol($sql); foreach ($languages AS $lang_id) { Index: core/units/related_searches/related_searches_config.php =================================================================== --- core/units/related_searches/related_searches_config.php (revision 14988) +++ core/units/related_searches/related_searches_config.php (working copy) @@ -35,7 +35,7 @@ ), 'IDField' => 'RelatedSearchId', 'StatusField' => Array('Enabled'), - 'TableName' => TABLE_PREFIX.'RelatedSearches', + 'TableName' => TABLE_PREFIX.'CategoryRelatedSearches', 'ParentTableKey' => 'ResourceId', 'ForeignKey' => 'ResourceId', 'ParentPrefix' => 'c', Index: core/units/relationship/relationship_config.php =================================================================== --- core/units/relationship/relationship_config.php (revision 14988) +++ core/units/relationship/relationship_config.php (working copy) @@ -42,7 +42,7 @@ ), 'IDField' => 'RelationshipId', 'StatusField' => Array('Enabled','Type'), - 'TableName' => TABLE_PREFIX.'Relationship', + 'TableName' => TABLE_PREFIX.'CatalogRelationships', 'ParentTableKey'=> 'ResourceId', 'ForeignKey' => 'SourceId', 'ParentPrefix' => 'p', Index: core/units/reviews/reviews_config.php =================================================================== --- core/units/reviews/reviews_config.php (revision 14988) +++ core/units/reviews/reviews_config.php (working copy) @@ -43,7 +43,7 @@ 'IDField' => 'ReviewId', 'StatusField' => Array ('Status'), // field, that is affected by Approve/Decline events - 'TableName' => TABLE_PREFIX.'ItemReview', + 'TableName' => TABLE_PREFIX.'CatalogReviews', 'ParentTableKey' => 'ResourceId', // linked field in master table 'ForeignKey' => 'ItemId', // linked field in subtable @@ -80,17 +80,17 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser pu ON pu.PortalUserId = %1$s.CreatedById', + LEFT JOIN ' . TABLE_PREFIX . 'Users pu ON pu.PortalUserId = %1$s.CreatedById', 'products' => ' SELECT %1$s.* %2$s FROM %1$s LEFT JOIN ' . TABLE_PREFIX . 'Products pr ON pr.ResourceId = %1$s.ItemId - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser pu ON pu.PortalUserId = %1$s.CreatedById', + LEFT JOIN ' . TABLE_PREFIX . 'Users pu ON pu.PortalUserId = %1$s.CreatedById', 'product' => ' SELECT %1$s.* %2$s FROM %1$s LEFT JOIN ' . TABLE_PREFIX . 'Products pr ON pr.ResourceId = %1$s.ItemId - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser pu ON pu.PortalUserId = %1$s.CreatedById', + LEFT JOIN ' . TABLE_PREFIX . 'Users pu ON pu.PortalUserId = %1$s.CreatedById', ), 'ItemSQLs' => Array ('' => 'SELECT * FROM %s'), @@ -138,7 +138,7 @@ 'type' => 'int', 'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'), - 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'PortalUser + 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Users WHERE `%s` = \'%s\' ', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', Index: core/units/site_domains/site_domains_config.php =================================================================== --- core/units/site_domains/site_domains_config.php (revision 14988) +++ core/units/site_domains/site_domains_config.php (working copy) @@ -111,22 +111,22 @@ ), 'PrimaryLanguageId' => Array ( 'type' => 'int', - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Language WHERE Enabled = 1 ORDER BY PackName ASC', 'option_key_field' => 'LanguageId', 'option_title_field' => 'PackName', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Languages WHERE Enabled = 1 ORDER BY PackName ASC', 'option_key_field' => 'LanguageId', 'option_title_field' => 'PackName', 'not_null' => 1, 'default' => 0 ), 'Languages' => Array ( 'type' => 'string', 'max_len' => 255, - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Language WHERE Enabled = 1 ORDER BY PackName ASC', 'option_key_field' => 'LanguageId', 'option_title_field' => 'PackName', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Languages WHERE Enabled = 1 ORDER BY PackName ASC', 'option_key_field' => 'LanguageId', 'option_title_field' => 'PackName', 'not_null' => 1, 'default' => '' ), 'PrimaryThemeId' => Array ( 'type' => 'int', - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Theme WHERE Enabled = 1 ORDER BY Name ASC', 'option_key_field' => 'ThemeId', 'option_title_field' => 'Name', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Themes WHERE Enabled = 1 ORDER BY Name ASC', 'option_key_field' => 'ThemeId', 'option_title_field' => 'Name', 'not_null' => 1, 'default' => 0 ), 'Themes' => Array ( 'type' => 'string', 'max_len' => 255, - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Theme WHERE Enabled = 1 ORDER BY Name ASC', 'option_key_field' => 'ThemeId', 'option_title_field' => 'Name', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Themes WHERE Enabled = 1 ORDER BY Name ASC', 'option_key_field' => 'ThemeId', 'option_title_field' => 'Name', 'not_null' => 1, 'default' => '' ), 'DomainIPRange' => Array ('type' => 'string', 'default' => NULL), Index: core/units/skins/skins_config.php =================================================================== --- core/units/skins/skins_config.php (revision 14988) +++ core/units/skins/skins_config.php (working copy) @@ -43,7 +43,7 @@ ), 'IDField' => 'SkinId', 'StatusField' => Array('IsPrimary'), - 'TableName' => TABLE_PREFIX.'Skins', + 'TableName' => TABLE_PREFIX.'AdminSkins', /* 'ForeignKey' => 'ParentId', // field title in TableName, linking record to a parent Index: core/units/spam_reports/spam_reports_config.php =================================================================== --- core/units/spam_reports/spam_reports_config.php (revision 14988) +++ core/units/spam_reports/spam_reports_config.php (working copy) @@ -55,8 +55,8 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN ' . TABLE_PREFIX . 'PortalUser reported_by ON reported_by.PortalUserId = %1$s.ReportedById - LEFT JOIN ' . TABLE_PREFIX . 'ItemReview review ON review.ReviewId = %1$s.ItemId AND %1$s.ItemPrefix LIKE "%rev"', + LEFT JOIN ' . TABLE_PREFIX . 'Users reported_by ON reported_by.PortalUserId = %1$s.ReportedById + LEFT JOIN ' . TABLE_PREFIX . 'CatalogReviews review ON review.ReviewId = %1$s.ItemId AND %1$s.ItemPrefix LIKE "%rev"', ), 'CalculatedFields' => Array ( @@ -84,7 +84,7 @@ 'ReportedOn' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => '#NOW#'), 'ReportedById' => Array ( 'type' => 'int', - 'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'), 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'sample_value' => 'Guest', + 'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'), 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Users WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'sample_value' => 'Guest', 'default' => NULL ) ), Index: core/units/structure/structure_config.php =================================================================== --- core/units/structure/structure_config.php (revision 14988) +++ core/units/structure/structure_config.php (working copy) @@ -72,7 +72,8 @@ 'TitleField' => 'Name', // field, used in bluebar when editing existing item - 'TableName' => TABLE_PREFIX.'Category', + 'TableName' => TABLE_PREFIX.'Categories', + 'CustomDataTableName' => TABLE_PREFIX . 'CategoryCustomData', 'TitlePresets' => Array( 'default' => Array( 'new_status_labels' => Array('st'=>'!la_title_Adding_Category!'), @@ -100,7 +101,7 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PermCache ON '.TABLE_PREFIX.'PermCache.CategoryId = %1$s.CategoryId', + LEFT JOIN '.TABLE_PREFIX.'CategoryPermissionsCache ON '.TABLE_PREFIX.'CategoryPermissionsCache.CategoryId = %1$s.CategoryId', '-virtual' => 'SELECT %1$s.* %2$s FROM %1$s', ), @@ -140,7 +141,7 @@ 'MetaKeywords' => Array('type' => 'string', 'default' => null), 'CachedDescendantCatsQty' => Array('type' => 'int', 'not_null' => 1, 'default' => 0), 'CachedNavbar' => Array('type' => 'string', 'formatter' => 'kMultiLanguage', 'default' => null), - 'CreatedById' => Array('type' => 'int', 'formatter' => 'kLEFTFormatter', 'options' => Array(USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), + 'CreatedById' => Array('type' => 'int', 'formatter' => 'kLEFTFormatter', 'options' => Array(USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'Users WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), 'ResourceId' => Array('type' => 'int', 'default' => null), 'ParentPath' => Array('type' => 'string', 'default' => null), 'TreeLeft' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), @@ -151,7 +152,7 @@ 'NewItem' => Array('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Auto', 1 => 'la_Always', 0 => 'la_Never'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2), 'PopItem' => Array('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Auto', 1 => 'la_Always', 0 => 'la_Never'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2), 'Modified' => Array('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => '#NOW#'), - 'ModifiedById' => Array('type' => 'int', 'formatter' => 'kLEFTFormatter', 'options' => Array(USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'PortalUser WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), + 'ModifiedById' => Array('type' => 'int', 'formatter' => 'kLEFTFormatter', 'options' => Array(USER_ROOT => 'root', USER_GUEST => 'Guest'),'left_sql'=>'SELECT %s FROM '.TABLE_PREFIX.'Users WHERE `%s` = \'%s\'', 'left_key_field' => 'PortalUserId', 'left_title_field' => 'Username', 'default' => NULL), 'CachedTemplate' => Array('type' => 'string', 'not_null' => 1, 'default' => ''), @@ -161,7 +162,7 @@ 'formatter' => 'kOptionsFormatter', 'options_sql' => ' SELECT CONCAT(tf.Description, " (", TRIM(TRAILING ".des" FROM TRIM(TRAILING ".tpl" FROM FileName) ), ")") AS Title, CONCAT(FilePath, "/", TRIM(TRAILING ".tpl" FROM FileName)) AS Value FROM ' . TABLE_PREFIX . 'ThemeFiles AS tf - LEFT JOIN ' . TABLE_PREFIX . 'Theme AS t ON t.ThemeId = tf.ThemeId + LEFT JOIN ' . TABLE_PREFIX . 'Themes AS t ON t.ThemeId = tf.ThemeId WHERE (t.Enabled = 1) AND (tf.FileName NOT LIKE "%%.elm.tpl") AND (tf.FileName NOT LIKE "%%.des.tpl") AND (tf.FilePath = "/designs")', 'option_key_field' => 'Value', 'option_title_field' => 'Title', 'not_null' => 1, 'default' => CATEGORY_TEMPLATE_INHERIT Index: core/units/themes/themes_config.php =================================================================== --- core/units/themes/themes_config.php (revision 14988) +++ core/units/themes/themes_config.php (working copy) @@ -90,7 +90,7 @@ ), ), - 'TableName' => TABLE_PREFIX.'Theme', + 'TableName' => TABLE_PREFIX.'Themes', 'SubItems' => Array('theme-file'), 'AutoDelete' => true, Index: core/units/translator/translator_config.php =================================================================== --- core/units/translator/translator_config.php (revision 14988) +++ core/units/translator/translator_config.php (working copy) @@ -44,7 +44,7 @@ 'VirtualFields' => Array( 'Original' => Array(), 'Language' => Array(), - 'SwitchLanguage' => Array('formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM '.TABLE_PREFIX.'Language', 'option_key_field' => 'LanguageId','option_title_field' => 'PackName'), + 'SwitchLanguage' => Array('formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM '.TABLE_PREFIX.'Languages', 'option_key_field' => 'LanguageId','option_title_field' => 'PackName'), 'Translation' => Array('type' => 'string', 'formatter' => 'kFormatter', 'using_fck' => 1, 'default' => ''), ), ); \ No newline at end of file Index: core/units/user_groups/user_groups_config.php =================================================================== --- core/units/user_groups/user_groups_config.php (revision 14988) +++ core/units/user_groups/user_groups_config.php (working copy) @@ -26,13 +26,13 @@ 'ListSQLs' => Array( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalGroup g ON %1$s.GroupId = g.GroupId - LEFT JOIN '.TABLE_PREFIX.'PortalUser u ON %1$s.PortalUserId = u.PortalUserId' + LEFT JOIN '.TABLE_PREFIX.'UserGroups g ON %1$s.GroupId = g.GroupId + LEFT JOIN '.TABLE_PREFIX.'Users u ON %1$s.PortalUserId = u.PortalUserId' ), 'ItemSQLs' => Array( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalGroup g ON %1$s.GroupId = g.GroupId - LEFT JOIN '.TABLE_PREFIX.'PortalUser u ON %1$s.PortalUserId = u.PortalUserId' + LEFT JOIN '.TABLE_PREFIX.'UserGroups g ON %1$s.GroupId = g.GroupId + LEFT JOIN '.TABLE_PREFIX.'Users u ON %1$s.PortalUserId = u.PortalUserId' ), 'CalculatedFields' => Array ( '' => Array( @@ -82,12 +82,12 @@ 'IDField' => 'GroupId', 'TitleField' => 'GroupName', - 'TableName' => TABLE_PREFIX.'UserGroup', + 'TableName' => TABLE_PREFIX.'UserGroupRelations', 'ListSQLs' => Array( ''=>' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalGroup g ON %1$s.GroupId = g.GroupId - LEFT JOIN '.TABLE_PREFIX.'%3$sPortalUser u ON %1$s.PortalUserId = u.PortalUserId'), + LEFT JOIN '.TABLE_PREFIX.'UserGroups g ON %1$s.GroupId = g.GroupId + LEFT JOIN '.TABLE_PREFIX.'%3$sUsers u ON %1$s.PortalUserId = u.PortalUserId'), 'AutoDelete' => true, 'AutoClone' => false, Index: core/units/user_groups/user_groups_eh.php =================================================================== --- core/units/user_groups/user_groups_eh.php (revision 14988) +++ core/units/user_groups/user_groups_eh.php (working copy) @@ -33,7 +33,7 @@ // don't insert duplicate group membership record $user_id = $this->Application->GetVar('u_id'); - $table_name = $this->Application->GetTempName(TABLE_PREFIX.'UserGroup', 'prefix:u'); + $table_name = $this->Application->GetTempName(TABLE_PREFIX.'UserGroupRelations', 'prefix:u'); $sql = 'SELECT GroupId FROM '.$table_name.' @@ -63,7 +63,7 @@ // don't insert duplicate group membership record $group_id = $this->Application->GetVar('g_id'); - $table_name = $this->Application->GetTempName(TABLE_PREFIX.'UserGroup', 'prefix:g'); + $table_name = $this->Application->GetTempName(TABLE_PREFIX.'UserGroupRelations', 'prefix:g'); $sql = 'SELECT PortalUserId FROM ' . $table_name . ' @@ -126,7 +126,7 @@ if ($event->Prefix == 'u-ug') { // allow deleting non-primary group of current user ($ids - groups) $sql = 'SELECT PrimaryGroupId - FROM ' . $this->Application->GetTempName(TABLE_PREFIX . 'PortalUser', 'prefix:u') . ' + FROM ' . $this->Application->GetTempName(TABLE_PREFIX . 'Users', 'prefix:u') . ' WHERE PortalUserId = ' . (int)$this->Application->GetVar('u_id'); $primary_group_id = (int)$this->Conn->GetOne($sql); @@ -142,7 +142,7 @@ $group_id = (int)$this->Application->GetVar('g_id'); $sql = 'SELECT PortalUserId - FROM ' . TABLE_PREFIX . 'PortalUser' . ' + FROM ' . TABLE_PREFIX . 'Users WHERE PortalUserId IN (' . implode(',', $ids) . ') AND PrimaryGroupId = ' . $group_id; $exclude_users = $this->Conn->GetCol($sql); Index: core/units/user_profile/user_profile_config.php =================================================================== --- core/units/user_profile/user_profile_config.php (revision 14988) +++ core/units/user_profile/user_profile_config.php (working copy) @@ -29,7 +29,7 @@ ), 'IDField' => 'VariableId', - 'TableName' => TABLE_PREFIX.'PersistantSessionData', + 'TableName' => TABLE_PREFIX.'UserPersistentSessionData', 'ForeignKey' => 'PortalUserId', 'ParentTableKey' => 'PortalUserId', Index: core/units/user_profile/user_profile_tp.php =================================================================== --- core/units/user_profile/user_profile_tp.php (revision 14988) +++ core/units/user_profile/user_profile_tp.php (working copy) @@ -70,7 +70,7 @@ /* @var $user kDBItem */ $sql = 'SELECT VariableValue, VariableName - FROM ' . TABLE_PREFIX . 'PersistantSessionData + FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE (PortalUserId = ' . $user->GetID() . ')'; $cache = $this->Conn->GetCol($sql, 'VariableName'); } Index: core/units/users/users_config.php =================================================================== --- core/units/users/users_config.php (revision 14994) +++ core/units/users/users_config.php (working copy) @@ -272,24 +272,25 @@ ), ), - 'TableName' => TABLE_PREFIX.'PortalUser', + 'TableName' => TABLE_PREFIX.'Users', + 'CustomDataTableName' => TABLE_PREFIX . 'UserCustomData', 'ListSQLs' => Array( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalGroup g ON %1$s.PrimaryGroupId = g.GroupId - LEFT JOIN '.TABLE_PREFIX.'%3$sPortalUserCustomData cust ON %1$s.ResourceId = cust.ResourceId - LEFT JOIN '.TABLE_PREFIX.'%3$sImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1', + LEFT JOIN '.TABLE_PREFIX.'UserGroups g ON %1$s.PrimaryGroupId = g.GroupId + LEFT JOIN '.TABLE_PREFIX.'%3$sUserCustomData cust ON %1$s.ResourceId = cust.ResourceId + LEFT JOIN '.TABLE_PREFIX.'%3$sCatalogImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1', 'online' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'UserSession s ON s.PortalUserId = %1$s.PortalUserId - LEFT JOIN '.TABLE_PREFIX.'PortalGroup g ON %1$s.PrimaryGroupId = g.GroupId - LEFT JOIN '.TABLE_PREFIX.'%3$sPortalUserCustomData cust ON %1$s.ResourceId = cust.ResourceId - LEFT JOIN '.TABLE_PREFIX.'%3$sImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1', + LEFT JOIN '.TABLE_PREFIX.'UserSessions s ON s.PortalUserId = %1$s.PortalUserId + LEFT JOIN '.TABLE_PREFIX.'UserGroups g ON %1$s.PrimaryGroupId = g.GroupId + LEFT JOIN '.TABLE_PREFIX.'%3$sUserCustomData cust ON %1$s.ResourceId = cust.ResourceId + LEFT JOIN '.TABLE_PREFIX.'%3$sCatalogImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1', ), 'ItemSQLs' => Array( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalGroup g ON %1$s.PrimaryGroupId = g.GroupId - LEFT JOIN '.TABLE_PREFIX.'%3$sPortalUserCustomData cust ON %1$s.ResourceId = cust.ResourceId - LEFT JOIN '.TABLE_PREFIX.'%3$sImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1', + LEFT JOIN '.TABLE_PREFIX.'UserGroups g ON %1$s.PrimaryGroupId = g.GroupId + LEFT JOIN '.TABLE_PREFIX.'%3$sUserCustomData cust ON %1$s.ResourceId = cust.ResourceId + LEFT JOIN '.TABLE_PREFIX.'%3$sCatalogImages img ON img.ResourceId = %1$s.ResourceId AND img.DefaultImg = 1', ), 'ListSortings' => Array ( @@ -390,11 +391,11 @@ 'PwResetConfirm' => Array ('default' => ''), 'PwRequestTime' => Array ('formatter' => 'kDateFormatter', 'default' => NULL), 'FrontLanguage' => Array ( - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Language ORDER BY PackName', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Languages ORDER BY PackName', 'option_key_field' => 'LanguageId', 'option_title_field' => 'LocalName', 'default' => NULL ), 'AdminLanguage' => Array ( - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Language ORDER BY PackName', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Languages ORDER BY PackName', 'option_key_field' => 'LanguageId', 'option_title_field' => 'LocalName', 'default' => NULL ), 'DisplayToPublic' => Array ( @@ -411,7 +412,7 @@ 'default' => 0 ), 'PrimaryGroupId' => Array ( - 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %1$s FROM ' . TABLE_PREFIX . 'PortalGroup WHERE Enabled = 1 AND FrontRegistration = 1', + 'formatter' => 'kOptionsFormatter', 'options_sql' => 'SELECT %1$s FROM ' . TABLE_PREFIX . 'UserGroups WHERE Enabled = 1 AND FrontRegistration = 1', 'option_key_field' => 'GroupId', 'option_title_field' => 'Name', 'default' => NULL ), 'OldStyleLogin' => Array ( Index: core/units/users/users_event_handler.php =================================================================== --- core/units/users/users_event_handler.php (revision 14989) +++ core/units/users/users_event_handler.php (working copy) @@ -110,7 +110,7 @@ if ( $group_id !== false ) { // show only users, that user doesn't belong to current group $sql = 'SELECT PortalUserId - FROM ' . $this->Application->GetTempName(TABLE_PREFIX . 'UserGroup', 'prefix:g') . ' + FROM ' . $this->Application->GetTempName(TABLE_PREFIX . 'UserGroupRelations', 'prefix:g') . ' WHERE GroupId = ' . (int)$group_id; $user_ids = $this->Conn->GetCol($sql); @@ -203,7 +203,7 @@ */ function OnSessionExpire(&$event) { - $this->Application->resetCounters('UserSession'); + $this->Application->resetCounters('UserSessions'); // place 2 of 2 (also in kHTTPQuery::getRedirectParams) $admin_url_params = Array ( @@ -551,7 +551,7 @@ if ($group_id) { // check, that group is allowed for Front-End $sql = 'SELECT GroupId - FROM ' . TABLE_PREFIX . 'PortalGroup + FROM ' . TABLE_PREFIX . 'UserGroups WHERE GroupId = ' . (int)$group_id . ' AND FrontRegistration = 1'; $group_id = $this->Conn->GetOne($sql); } @@ -576,7 +576,7 @@ $primary_group_id = $object->GetDBField('PrimaryGroupId'); if ($primary_group_id) { - $ug_table = TABLE_PREFIX . 'UserGroup'; + $ug_table = TABLE_PREFIX . 'UserGroupRelations'; if ( $object->IsTempTable() ) { $ug_table = $this->Application->GetTempName($ug_table, 'prefix:' . $event->Prefix); @@ -787,7 +787,7 @@ 'GroupId' => $this->Application->ConfigValue('User_SubscriberGroup'), ); - $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'UserGroup'); + $this->Conn->doInsert($fields_hash, TABLE_PREFIX . 'UserGroupRelations'); } $this->Application->EmailEventAdmin('USER.SUBSCRIBE'); @@ -803,7 +803,7 @@ { $group_id = $this->Application->ConfigValue('User_SubscriberGroup'); - $sql = 'DELETE FROM ' . TABLE_PREFIX . 'UserGroup + $sql = 'DELETE FROM ' . TABLE_PREFIX . 'UserGroupRelations WHERE PortalUserId = ' . $user_id . ' AND GroupId = ' . $group_id; $this->Conn->Query($sql); @@ -1013,7 +1013,7 @@ // send pre-expiration reminders: begin $pre_expiration = adodb_mktime() + $this->Application->ConfigValue('User_MembershipExpirationReminder') * 3600 * 24; $sql = 'SELECT PortalUserId, GroupId - FROM '.TABLE_PREFIX.'UserGroup + FROM '.TABLE_PREFIX.'UserGroupRelations WHERE (MembershipExpires IS NOT NULL) AND (ExpirationReminderSent = 0) AND (MembershipExpires < '.$pre_expiration.')'; $skip_clause = $event->getEventParam('skip_clause'); @@ -1029,7 +1029,7 @@ $this->Application->EmailEventAdmin('USER.MEMBERSHIP.EXPIRATION.NOTICE'); $conditions[] = '(PortalUserId = '.$record['PortalUserId'].' AND GroupId = '.$record['GroupId'].')'; } - $sql = 'UPDATE '.TABLE_PREFIX.'UserGroup + $sql = 'UPDATE '.TABLE_PREFIX.'UserGroupRelations SET ExpirationReminderSent = 1 WHERE '.implode(' OR ', $conditions); $this->Conn->Query($sql); @@ -1038,7 +1038,7 @@ // remove users from groups with expired membership: begin $sql = 'SELECT PortalUserId - FROM '.TABLE_PREFIX.'UserGroup + FROM '.TABLE_PREFIX.'UserGroupRelations WHERE (MembershipExpires IS NOT NULL) AND (MembershipExpires < '.adodb_mktime().')'; $user_ids = $this->Conn->GetCol($sql); if ($user_ids) { @@ -1047,7 +1047,7 @@ $this->Application->EmailEventAdmin('USER.MEMBERSHIP.EXPIRED'); } } - $sql = 'DELETE FROM '.TABLE_PREFIX.'UserGroup + $sql = 'DELETE FROM '.TABLE_PREFIX.'UserGroupRelations WHERE (MembershipExpires IS NOT NULL) AND (MembershipExpires < '.adodb_mktime().')'; $this->Conn->Query($sql); // remove users from groups with expired membership: end @@ -1251,7 +1251,7 @@ } if ( $ids ) { - $q = 'DELETE FROM ' . TABLE_PREFIX . 'PersistantSessionData WHERE PortalUserId IN (' . join(',', $ids) . ') AND + $q = 'DELETE FROM ' . TABLE_PREFIX . 'UserPersistentSessionData WHERE PortalUserId IN (' . join(',', $ids) . ') AND (VariableName LIKE "%_columns_%" OR VariableName LIKE "%_filter%" @@ -1440,7 +1440,7 @@ // deletes sessions from users, that are no longer active if (($prev_status != $new_status) && ($new_status != STATUS_ACTIVE)) { $sql = 'SELECT SessionKey - FROM ' . TABLE_PREFIX . 'UserSession + FROM ' . TABLE_PREFIX . 'UserSessions WHERE PortalUserId = ' . $user_id; $session_ids = $this->Conn->GetCol($sql); @@ -1652,7 +1652,7 @@ $table_name = $this->Application->getUnitOption('ug', 'TableName'); // 1. mark group as primary - $sql = 'UPDATE ' . TABLE_PREFIX . 'PortalUser + $sql = 'UPDATE ' . TABLE_PREFIX . 'Users SET PrimaryGroupId = ' . $primary_group_id . ' WHERE PortalUserId IN (' . implode(',', $user_ids) . ')'; $this->Conn->Query($sql); Index: core/units/users/users_item.php =================================================================== --- core/units/users/users_item.php (revision 14988) +++ core/units/users/users_item.php (working copy) @@ -30,7 +30,7 @@ if ( $user_groups === false || $force_reload ) { // primary group goes first $sql = 'SELECT GroupId - FROM ' . TABLE_PREFIX . 'UserGroup + FROM ' . TABLE_PREFIX . 'UserGroupRelations WHERE (PortalUserId = ' . $this->GetID() . ') AND ( (MembershipExpires IS NULL) OR (MembershipExpires >= ' . adodb_mktime() . ') ) ORDER BY IF(GroupId = ' . $this->GetDBField('PrimaryGroupId') . ', 1, 0) DESC'; $groups = $this->Conn->GetCol($sql); @@ -89,7 +89,7 @@ $group_id = $this->Application->ConfigValue('User_SubscriberGroup'); $sql = 'SELECT GroupId - FROM ' . TABLE_PREFIX . 'UserGroup + FROM ' . TABLE_PREFIX . 'UserGroupRelations WHERE (PortalUserId = ' . $this->GetID() . ') AND (GroupId = ' . $group_id . ')'; return $this->Conn->GetOne($sql); Index: core/units/users/users_tag_processor.php =================================================================== --- core/units/users/users_tag_processor.php (revision 14988) +++ core/units/users/users_tag_processor.php (working copy) @@ -266,7 +266,7 @@ if (!isset($loggedin_status[$this->Special])) { $user_ids = $object->GetCol($object->IDField); $sql = 'SELECT LastAccessed, '.$object->IDField.' - FROM '.TABLE_PREFIX.'UserSession + FROM '.TABLE_PREFIX.'UserSessions WHERE (PortalUserId IN ('.implode(',', $user_ids).'))'; $loggedin_status[$this->Special] = $this->Conn->GetCol($sql, $object->IDField); } Index: core/units/visits/visits_config.php =================================================================== --- core/units/visits/visits_config.php (revision 14988) +++ core/units/visits/visits_config.php (working copy) @@ -55,7 +55,7 @@ ), 'IDField' => 'VisitId', - 'TableName' => TABLE_PREFIX.'Visits', + 'TableName' => TABLE_PREFIX.'UserVisits', 'PermSection' => Array ('main' => 'in-portal:visits'), @@ -100,25 +100,25 @@ 'ListSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalUser u ON %1$s.PortalUserId = u.PortalUserId', + LEFT JOIN '.TABLE_PREFIX.'Users u ON %1$s.PortalUserId = u.PortalUserId', 'incommerce' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalUser u ON %1$s.PortalUserId = u.PortalUserId + LEFT JOIN '.TABLE_PREFIX.'Users u ON %1$s.PortalUserId = u.PortalUserId LEFT JOIN '.TABLE_PREFIX.'Affiliates af ON %1$s.AffiliateId = af.AffiliateId - LEFT JOIN '.TABLE_PREFIX.'PortalUser au ON af.PortalUserId = au.PortalUserId + LEFT JOIN '.TABLE_PREFIX.'Users au ON af.PortalUserId = au.PortalUserId LEFT JOIN '.TABLE_PREFIX.'Orders ord ON %1$s.VisitId = ord.VisitId', ), 'ItemSQLs' => Array ( '' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalUser u ON %1$s.PortalUserId = u.PortalUserId', + LEFT JOIN '.TABLE_PREFIX.'Users u ON %1$s.PortalUserId = u.PortalUserId', 'incommerce' => ' SELECT %1$s.* %2$s FROM %1$s - LEFT JOIN '.TABLE_PREFIX.'PortalUser u ON %1$s.PortalUserId = u.PortalUserId + LEFT JOIN '.TABLE_PREFIX.'Users u ON %1$s.PortalUserId = u.PortalUserId LEFT JOIN '.TABLE_PREFIX.'Affiliates af ON %1$s.AffiliateId = af.AffiliateId - LEFT JOIN '.TABLE_PREFIX.'PortalUser au ON af.PortalUserId = au.PortalUserId + LEFT JOIN '.TABLE_PREFIX.'Users au ON af.PortalUserId = au.PortalUserId LEFT JOIN '.TABLE_PREFIX.'Orders ord ON %1$s.VisitId = ord.VisitId', ), @@ -133,7 +133,7 @@ 'VisitDate' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'custom_filter' => 'date_range', 'default' => NULL), 'Referer' => Array ('type' => 'string','not_null' => '1','default' => ''), 'IPAddress' => Array ('type' => 'string','not_null' => '1','default' => ''), - 'AffiliateId' => Array ('type' => 'int','formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (0 => 'lu_None'), 'left_sql' => 'SELECT %s FROM '.TABLE_PREFIX.'Affiliates af LEFT JOIN '.TABLE_PREFIX.'PortalUser pu ON pu.PortalUserId = af.PortalUserId WHERE `%s` = \'%s\'','left_key_field' => 'AffiliateId','left_title_field' => 'Username','not_null'=>1,'default'=>0), + 'AffiliateId' => Array ('type' => 'int','formatter' => 'kLEFTFormatter', 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'options' => Array (0 => 'lu_None'), 'left_sql' => 'SELECT %s FROM '.TABLE_PREFIX.'Affiliates af LEFT JOIN '.TABLE_PREFIX.'Users pu ON pu.PortalUserId = af.PortalUserId WHERE `%s` = \'%s\'','left_key_field' => 'AffiliateId','left_title_field' => 'Username','not_null'=>1,'default'=>0), 'PortalUserId' => Array ('type' => 'int','not_null' => '1','default' => USER_GUEST), ), Index: tools/show_cache.php =================================================================== --- tools/show_cache.php (revision 14975) +++ tools/show_cache.php (working copy) @@ -43,7 +43,7 @@ } else { $sql = 'SELECT VarName - FROM ' . TABLE_PREFIX . 'Cache'; + FROM ' . TABLE_PREFIX . 'SystemCache'; $var_names = $application->Conn->GetCol($sql);