More fixes for fetchUserData(), missing template added
authorRoland Häder <roland@mxchange.org>
Wed, 4 Nov 2009 07:40:19 +0000 (07:40 +0000)
committerRoland Häder <roland@mxchange.org>
Wed, 4 Nov 2009 07:40:19 +0000 (07:40 +0000)
.gitattributes
inc/functions.php
inc/mysql-manager.php
templates/de/html/menu/menu_member_advert_logout.tpl [new file with mode: 0644]

index ca82c55..fdbcdc6 100644 (file)
@@ -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
index 90e2bc5..7908206 100644 (file)
@@ -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);
 
index 343477e..e1f912c 100644 (file)
@@ -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 (file)
index 0000000..7014e93
--- /dev/null
@@ -0,0 +1,6 @@
+<tr>
+       <td class="menu_advert">
+               <a href="{?URL?}/modules.php?module=index&amp;what=impressum" target="_blank">Hier k&ouml;nnte Ihre Werbung stehen!</a>
+               <!-- Fuegen Sie hier Ihre Werbung ein! //-->
+       </td>
+</tr>