X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=surfbar.php;h=8ad2c2af012473fd73719298e06bc00aa866b8fb;hb=f64d7201f0d4bf966d55bcdc85ce206d124dfe14;hp=63facf329f15a92886fa1e1fabc9bd9c8fb0a6d7;hpb=9bc2a494fae1a98f0873a6f3bd8c878b09124b9f;p=mailer.git diff --git a/surfbar.php b/surfbar.php index 63facf329f..8ad2c2af01 100644 --- a/surfbar.php +++ b/surfbar.php @@ -14,11 +14,9 @@ * $Date:: $ * * $Tag:: 0.2.1-FINAL $ * * $Author:: $ * - * Needs to be in all Files and every File needs "svn propset * - * svn:keywords Date Revision" (autoprobset!) at least!!!!!! * * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * - * Copyright (c) 2009, 2010 by Mailer Developer Team * + * Copyright (c) 2009 - 2011 by Mailer Developer Team * * For more information visit: http://www.mxchange.org * * * * This program is free software; you can redistribute it and/or modify * @@ -70,10 +68,10 @@ if (!isMember()) { // Is the form sent? if ((isFormSent()) && (isPostRequestParameterSet('id')) && (isPostRequestParameterSet('password'))) { // Do the login procedure - $URL = doUserLogin(postRequestParameter('id'), postRequestParameter('password'), basename(__FILE__), basename(__FILE__) . '?code='); + $url = doUserLogin(postRequestParameter('id'), postRequestParameter('password'), basename(__FILE__), basename(__FILE__) . '?code='); // And redirect to the URL - redirectToUrl($URL); + redirectToUrl($url); } else { // Load header loadIncludeOnce('inc/header.php'); @@ -81,7 +79,7 @@ if (!isMember()) { // Is there a 'code' provided? if (isGetRequestParameterSet('code')) { // Then generate an error message - loadTemplate('admin_settings_saved', false, getMessageFromErrorCode(getRequestParameter('code'))); + displayMessage(getMessageFromErrorCode(getRequestParameter('code'))); } // END - if // Display login form @@ -122,12 +120,9 @@ if ((SURFBAR_CHECK_RELOAD_FULL()) || ((isGetRequestParameterSet('frame')) && (in // This makes the footer appear again unsetGetRequestParameter('frame'); } elseif ((isGetRequestParameterSet('frame')) && (getRequestParameter('frame') == 'stats')) { - // Get total points amount - $points = countSumTotalData(getMemberId(), 'user_points', 'points') - countSumTotalData(getMemberId(), 'user_data', 'used_points'); - // Prepare content $content = array( - 'points' => $points, + 'points' => getTotalPoints(getMemberId()), 'reload' => (getConfig('surfbar_stats_reload') * 1000) ); @@ -168,6 +163,9 @@ if ((SURFBAR_CHECK_RELOAD_FULL()) || ((isGetRequestParameterSet('frame')) && (in // Then load waiting page SURFBAR_RELOAD_TO_STOP_PAGE(); } // END - if + + // Load header to avoid a bug + loadIncludeOnce('inc/header.php'); } else { // Reload to stop frame! SURFBAR_RELOAD_TO_STOP_PAGE(); @@ -179,16 +177,11 @@ if ((SURFBAR_CHECK_RELOAD_FULL()) || ((isGetRequestParameterSet('frame')) && (in // Prepare content $content = ''; - // Determine template name - $templateName = SURFBAR_DETERMINE_TEMPLATE_NAME(); - - // Load header in frameset mode is the default - $isFrameset = true; - // Frame "top" set? if ((isGetRequestParameterSet('frame')) && (getRequestParameter('frame') == 'top')) { // Determine next id $nextId = SURFBAR_DETERMINE_NEXT_ID(); + //* DEBUG: */ die('nextId='.$nextId); // Is there a valid id? if ($nextId > 0) { @@ -212,6 +205,9 @@ if ((SURFBAR_CHECK_RELOAD_FULL()) || ((isGetRequestParameterSet('frame')) && (in // Load header loadIncludeOnce('inc/header.php'); + // Determine template name + $templateName = SURFBAR_DETERMINE_TEMPLATE_NAME(); + // Load that template //* DEBUG: */ die('templateName=' . $templateName . '
content=
' . print_r($content, true) . '
'); loadTemplate($templateName, false, $content);