From: Roland Häder Date: Tue, 27 Nov 2012 22:01:58 +0000 (+0000) Subject: Some improvements: X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=commitdiff_plain;h=b3db3a0ef875532db39f2365b52be8a576f0b796 Some improvements: - "noindex_metadata.tpl is now the default (noindex, etc.) template for robot control - added filter for 'module=confirm'" - TODOs.txt updated --- diff --git a/.gitattributes b/.gitattributes index 2e90ca011b..a02b84851c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1973,6 +1973,7 @@ templates/de/html/member/member_menu_bottom.tpl svneol=native#text/plain templates/de/html/member/member_menu_row.tpl svneol=native#text/plain templates/de/html/member/member_menu_start.tpl svneol=native#text/plain templates/de/html/member/member_menu_title.tpl svneol=native#text/plain +templates/de/html/member/member_metadata.tpl svneol=native#text/plain templates/de/html/member/member_mydata_button.tpl svneol=native#text/plain templates/de/html/member/member_mydata_edit.tpl svneol=native#text/plain templates/de/html/member/member_mydata_overview.tpl svneol=native#text/plain @@ -2065,6 +2066,7 @@ templates/de/html/menu/menu_what_begin.tpl svneol=native#text/plain templates/de/html/menu/menu_what_end.tpl svneol=native#text/plain templates/de/html/message.tpl svneol=native#text/plain templates/de/html/metadata.tpl svneol=native#text/plain +templates/de/html/noindex_metadata.tpl svneol=native#text/plain templates/de/html/online_now.tpl svneol=native#text/plain templates/de/html/page_body.tpl svneol=native#text/plain templates/de/html/page_footer.tpl svneol=native#text/plain diff --git a/DOCS/TODOs.txt b/DOCS/TODOs.txt index ba1aef8f21..6c65c7f197 100644 --- a/DOCS/TODOs.txt +++ b/DOCS/TODOs.txt @@ -57,9 +57,9 @@ ./inc/functions.php:1190: // @TODO Are these convertions still required? ./inc/functions.php:1211:// @TODO Rewrite this function to use readFromFile() and writeToFile() ./inc/functions.php:1816: // @TODO Find a way to cache this -./inc/functions.php:1921: // @TODO This is still very static, rewrite it somehow -./inc/functions.php:2125: // @TODO Rename column data_type to e.g. mail_status -./inc/functions.php:2475:// @TODO cacheFiles is not yet supported +./inc/functions.php:1920: // @TODO This is still very static, rewrite it somehow +./inc/functions.php:2124: // @TODO Rename column data_type to e.g. mail_status +./inc/functions.php:2474:// @TODO cacheFiles is not yet supported ./inc/gen_sql_patches.php:95:// @TODO Rewrite this to a filter ./inc/header.php:66:// @TODO Find a way to not use direct module comparison ./inc/install-functions.php:402: // @TODO Comparing with DEFAULT_MAIN_TITLE doesn't work diff --git a/inc/extensions/ext-sql_patches.php b/inc/extensions/ext-sql_patches.php index aff3816022..40a8e3a95d 100644 --- a/inc/extensions/ext-sql_patches.php +++ b/inc/extensions/ext-sql_patches.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.9.5'); +setThisExtensionVersion('0.9.6'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2', '0.7.3', '0.7.4', '0.7.5', '0.7.6', '0.7.7', '0.7.8', '0.7.9', '0.8.0', '0.8.1', '0.8.2', '0.8.3', '0.8.4', '0.8.5', '0.8.6', '0.8.7', '0.8.8', '0.8.9', '0.9.0', '0.9.1', '0.9.2', '0.9.3', '0.9.4', '0.9.5')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2', '0.7.3', '0.7.4', '0.7.5', '0.7.6', '0.7.7', '0.7.8', '0.7.9', '0.8.0', '0.8.1', '0.8.2', '0.8.3', '0.8.4', '0.8.5', '0.8.6', '0.8.7', '0.8.8', '0.8.9', '0.9.0', '0.9.1', '0.9.2', '0.9.3', '0.9.4', '0.9.5', '0.9.6')); // Keep this extension always active! setExtensionAlwaysActive('Y'); @@ -990,6 +990,14 @@ PRIMARY KEY (`server_name_id`) // Update notes (these will be set as task text!) setExtensionUpdateNotes("Menüpunkt umbenannt, da "config" nur für die Konfigurationstabelle {?_MYSQL_PREFIX?}_config ist."); break; + + case '0.9.6': // SQL queries for v0.9.6 + // Register filter + registerFilter(__FILE__, __LINE__, 'determine_menu_mode', 'DETERMINE_MENU_MODE_GENERIC', FALSE, TRUE, isExtensionDryRun()); + + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Filter hinzugefügt, der den Menümodus für weitere von dieser Erweiterung benutzten Module erkennen soll."); + break; } // END - switch break; diff --git a/inc/filters.php b/inc/filters.php index bd804baf9b..98cf7eb463 100644 --- a/inc/filters.php +++ b/inc/filters.php @@ -1380,5 +1380,18 @@ WHERE return $filterData; } +// Filter for detecting menu mode +function FILTER_DETERMINE_MENU_MODE_GENERIC ($filterData) { + // "Detect" it + switch (getModule()) { + case 'confirm': // Login script is 'member' + $filterData = 'member'; + break; + } // END - switch + + // Return filter data + return $filterData; +} + // [EOF] ?> diff --git a/inc/libs/bonus_functions.php b/inc/libs/bonus_functions.php index cdd11a792d..3bed18ebe6 100644 --- a/inc/libs/bonus_functions.php +++ b/inc/libs/bonus_functions.php @@ -364,6 +364,18 @@ function getLoginTimeout () { return $GLOBALS[__FUNCTION__]; } +// Getter for login_bonus +function getLoginBonus () { + // Is there cache? + if (!isset($GLOBALS[__FUNCTION__])) { + // Determine it + $GLOBALS[__FUNCTION__] = getConfig('login_bonus'); + } // END - if + + // Return cache + return $GLOBALS[__FUNCTION__]; +} + // Getter for bonus_ref function getBonusRef () { // Is there cache? diff --git a/inc/module-functions.php b/inc/module-functions.php index befb470dc4..9fdd7d36ff 100644 --- a/inc/module-functions.php +++ b/inc/module-functions.php @@ -529,8 +529,8 @@ function doIncludeModule () { function getMenuModeFromModule () { // Is cache set? if (!isset($GLOBALS[__FUNCTION__])) { - // Default is NULL - $GLOBALS[__FUNCTION__] = NULL; + // Default is 'noindex' which is invalid for SQL tables but okay for meta data template + $GLOBALS[__FUNCTION__] = 'noindex'; // Determine it hard-coded if (getModule() == 'login') { diff --git a/templates/de/html/member/member_metadata.tpl b/templates/de/html/member/member_metadata.tpl new file mode 100644 index 0000000000..4633e1d71e --- /dev/null +++ b/templates/de/html/member/member_metadata.tpl @@ -0,0 +1 @@ + diff --git a/templates/de/html/noindex_metadata.tpl b/templates/de/html/noindex_metadata.tpl new file mode 100644 index 0000000000..4633e1d71e --- /dev/null +++ b/templates/de/html/noindex_metadata.tpl @@ -0,0 +1 @@ +