From: Roland Häder Date: Wed, 4 Nov 2009 07:40:19 +0000 (+0000) Subject: More fixes for fetchUserData(), missing template added X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=e40fe9b587b688cf0fe64f12f50725a27479b929;p=mailer.git More fixes for fetchUserData(), missing template added --- diff --git a/.gitattributes b/.gitattributes index ca82c559f5..fdbcdc6c97 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1549,6 +1549,7 @@ templates/de/html/menu/menu_member_advert_account.tpl -text templates/de/html/menu/menu_member_advert_bank.tpl -text templates/de/html/menu/menu_member_advert_end.tpl -text templates/de/html/menu/menu_member_advert_extras.tpl -text +templates/de/html/menu/menu_member_advert_logout.tpl -text templates/de/html/menu/menu_member_advert_main.tpl -text templates/de/html/menu/menu_member_advert_order.tpl -text templates/de/html/menu/menu_member_advert_rals.tpl -text diff --git a/inc/functions.php b/inc/functions.php index 90e2bc5058..7908206a7c 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -3672,7 +3672,7 @@ function isTemplateCached ($template) { // Flushes non-flushed template cache to disk function flushTemplateCache ($template, $eval) { // Is this cache flushed? - if (!isTemplateCached($template)) { + if ((!isTemplateCached($template)) && ($eval != '404')) { // Generate FQFN $FQFN = sprintf("%s_compiled/templates/%s.tpl.cache", getConfig('CACHE_PATH'), $template); diff --git a/inc/mysql-manager.php b/inc/mysql-manager.php index 343477e891..e1f912c95f 100644 --- a/inc/mysql-manager.php +++ b/inc/mysql-manager.php @@ -583,6 +583,9 @@ function isMember () { } elseif (getUserId() == 0) { // No member return false; + } else { + // Transfer userid=>current + setCurrentUserid(getUserId()); } // Init global user data array @@ -635,7 +638,7 @@ function fetchUserData ($userid, $column='userid') { if ($userid < 1) { // Invalid, so abort here debug_report_bug('User id ' . $userid . ' is invalid.'); - } elseif (isset($GLOBALS['user_data'][$userid])) { + } elseif (isUserDataValid()) { // Use cache, so it is fine return true; } diff --git a/templates/de/html/menu/menu_member_advert_logout.tpl b/templates/de/html/menu/menu_member_advert_logout.tpl new file mode 100644 index 0000000000..7014e93faa --- /dev/null +++ b/templates/de/html/menu/menu_member_advert_logout.tpl @@ -0,0 +1,6 @@ + + + Hier könnte Ihre Werbung stehen! + + +