X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fadmin.php;h=2aa70e1b6b2cff24506a8b93326e84001b2d3a0d;hb=dd3d672d132afc9414fea64f4feb61b2f1e9d561;hp=889af1f25d99cc59ae119a5cb974253c2ae89ca7;hpb=2379934be6a196a54f4155bb8e24c49b20736969;p=mailer.git diff --git a/inc/modules/admin.php b/inc/modules/admin.php index 889af1f25d..2aa70e1b6b 100644 --- a/inc/modules/admin.php +++ b/inc/modules/admin.php @@ -17,7 +17,7 @@ * -------------------------------------------------------------------- * * 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 * @@ -244,25 +244,8 @@ if (!isAdminRegistered()) { // Which status do we have? switch ($ret) { case 'done': // Admin and password are okay, so we log in now - // Construct URL and redirect - $url = 'modules.php?module=admin&'; - - // Rewrite overview module - if (getWhat() == 'overview') { - setAction(getActionFromModuleWhat(getModule(), getWhat())); - } // END - if - - // Add data to URL - if (isWhatSet()) { - $url .= 'what=' . getWhat(); - } elseif (isActionSet()) { - $url .= 'action=' . getAction(); - } elseif (isGetRequestElementSet('area')) { - $url .= 'area=' . getRequestElement('area'); - } - // Load URL - redirectToUrl($url); + redirectToUrl('modules.php?' . addAllGetRequestParameters()); break; case '404': // Administrator login not found @@ -329,31 +312,8 @@ if (!isAdminRegistered()) { } // END - if } // END - if - // Load login form - if (isWhatSet()) { - // Restore old what value - $content = merge_array($content, array('target' => 'what', 'value' => getWhat())); - } elseif (isActionSet()) { - if (getAction() != 'logout') { - // Restore old action value - $content = merge_array($content, array('target' => 'action', 'value' => getAction())); - } else { - // Set default values - $content = merge_array($content, array('target' => 'action', 'value' => 'login')); - } - } elseif (isGetRequestElementSet('area')) { - // Restore old area value - $content = merge_array( - $content, - array( - 'target' => 'area', - 'value' => getRequestElement('area') - ) - ); - } else { - // Set default values - $content = merge_array($content, array('target' => 'action', 'value' => 'login')); - } + // Add all parameter + $content['all_parameter'] = addAllGetRequestParameters(); // Load login form template loadTemplate('admin_login_form', false, $content); @@ -401,7 +361,9 @@ if (!isAdminRegistered()) { $area = 'entrance'; // Check for similar URL variable - if (isGetRequestElementSet('area')) $area = getRequestElement('area'); + if (isGetRequestElementSet('area')) { + $area = getRequestElement('area'); + } // END - if // Load logical-area menu-system file loadIncludeOnce('inc/modules/admin/lasys-inc.php'); @@ -409,8 +371,10 @@ if (!isAdminRegistered()) { // Create new-style menu system will logical areas doAdminLogicalArea($area, $action, getWhat()); } else { - // This little call constructs the whole default old and lacky menu system - // on left side. It also renders the content on right side + /* + * This little call constructs the whole default old and lacky menu system + * on left side. It also renders the content on right side + */ doAdminAction(); } break;