* -------------------------------------------------------------------- *
* Copyright (c) 2003 - 2009 by Roland Haeder *
* Copyright (c) 2009 - 2011 by Mailer Developer Team *
- * For more information visit: http://www.mxchange.org *
+ * For more information visit: http://mxchange.org *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
setContentType('text/html');
// Is a frame active?
-if (isGetRequestParameterSet('frame')) {
+if (isGetRequestElementSet('frame')) {
// Then we need to set header_sent to 0
$GLOBALS['header_sent'] = '0';
} // END - if
// Should we display login window or redirect to main page?
if ((getConfig('surfbar_guest_login_form') == 'Y') && (isExtensionActive('user'))) {
// Is the form sent?
- if ((isFormSent()) && (isPostRequestParameterSet('id')) && (isPostRequestParameterSet('password'))) {
+ if ((isFormSent()) && (isPostRequestElementSet('id')) && (isPostRequestElementSet('password'))) {
// Do the login procedure
- $url = doUserLogin(postRequestParameter('id'), postRequestParameter('password'), basename(__FILE__), basename(__FILE__) . '?code=');
+ $url = doUserLogin(postRequestElement('id'), postRequestElement('password'), basename(__FILE__), basename(__FILE__) . '?code=');
// And redirect to the URL
redirectToUrl($url);
loadIncludeOnce('inc/header.php');
// Is there a 'code' provided?
- if (isGetRequestParameterSet('code')) {
+ if (isGetRequestElementSet('code')) {
// Then generate an error message
- displayMessage(getMessageFromErrorCode(getRequestParameter('code')));
+ displayMessage(getMessageFromErrorCode(getRequestElement('code')));
} // END - if
// Display login form
SURFBAR_HANDLE_SELF_MAINTENANCE();
// Is there a check value?
-if ((SURFBAR_CHECK_RELOAD_FULL()) || ((isGetRequestParameterSet('frame')) && (in_array(getRequestParameter('frame'), array('stop', 'stop2', 'stats', 'textlinks'))))) {
+if ((SURFBAR_CHECK_RELOAD_FULL()) || ((isGetRequestElementSet('frame')) && (in_array(getRequestElement('frame'), array('stop', 'stop2', 'stats', 'textlinks'))))) {
// Reload-lock is full, surfbar stopped so...
// Load header
loadIncludeOnce('inc/header.php');
// Load template
- if (((isGetRequestParameterSet('frame')) && (getRequestParameter('frame') == 'stop2')) || (!isGetRequestParameterSet('frame'))) {
+ if (((isGetRequestElementSet('frame')) && (getRequestElement('frame') == 'stop2')) || (!isGetRequestElementSet('frame'))) {
// Load template for "start" page
loadTemplate('surfbar_frame_start');
loadTemplate('surfbar_start_banner');
// This makes the footer appear again
- unsetGetRequestParameter('frame');
- } elseif ((isGetRequestParameterSet('frame')) && (getRequestParameter('frame') == 'stats')) {
+ unsetGetRequestElement('frame');
+ } elseif ((isGetRequestElementSet('frame')) && (getRequestElement('frame') == 'stats')) {
// Prepare content
$content = array(
'points' => getTotalPoints(getMemberId()),
// Load template for "stats" page
loadTemplate('surfbar_frame_stats', false, $content);
- } elseif ((isGetRequestParameterSet('frame')) && (getRequestParameter('frame') == 'textlinks')) {
+ } elseif ((isGetRequestElementSet('frame')) && (getRequestElement('frame') == 'textlinks')) {
// Prepare content
$content = array(
'reload' => (getConfig('surfbar_stats_reload') * 1000)
// Load template for stopped surfbar
loadTemplate('surfbar_stopped', false, $content);
}
-} elseif ((isGetRequestParameterSet('check')) && (isGetRequestParameterSet('id')) && (isGetRequestParameterSet('salt'))) {
+} elseif ((isGetRequestElementSet('check')) && (isGetRequestElementSet('id')) && (isGetRequestElementSet('salt'))) {
// Dummy next id get
- SURFBAR_DETERMINE_NEXT_ID(getRequestParameter('id'));
+ SURFBAR_DETERMINE_NEXT_ID(getRequestElement('id'));
// Check reload lock and validation code
- if ((!SURFBAR_CHECK_RELOAD_LOCK(getRequestParameter('id'))) && (SURFBAR_CHECK_VALIDATION_CODE(getRequestParameter('id'), getRequestParameter('check'), getRequestParameter('salt')))) {
+ if ((!SURFBAR_CHECK_RELOAD_LOCK(getRequestElement('id'))) && (SURFBAR_CHECK_VALIDATION_CODE(getRequestElement('id'), getRequestElement('check'), getRequestElement('salt')))) {
// Lock the URL (id) down
- SURFBAR_LOCKDOWN_ID(getRequestParameter('id'));
+ SURFBAR_LOCKDOWN_ID(getRequestElement('id'));
// Code is valid so pay points here
SURFBAR_PAY_POINTS();
// 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();
// 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')) {
+ if ((isGetRequestElementSet('frame')) && (getRequestElement('frame') == 'top')) {
// Determine next id
$nextId = SURFBAR_DETERMINE_NEXT_ID();
+ //* DEBUG: */ die('nextId='.$nextId);
// Is there a valid id?
if ($nextId > 0) {
// Load new URL
SURFBAR_RELOAD_TO_STOP_PAGE('stop');
}
- } elseif ((isGetRequestParameterSet('frame')) && (getRequestParameter('frame') == 'start')) {
+ } elseif ((isGetRequestElementSet('frame')) && (getRequestElement('frame') == 'start')) {
// Starter frame found so let the footer display
- unsetGetRequestParameter('frame');
+ unsetGetRequestElement('frame');
}
// Load header
loadIncludeOnce('inc/header.php');
+ // Determine template name
+ $templateName = SURFBAR_DETERMINE_TEMPLATE_NAME();
+
// Load that template
//* DEBUG: */ die('templateName=' . $templateName . '<br /><strong>content</strong>=<pre>' . print_r($content, true) . '</pre>');
loadTemplate($templateName, false, $content);