Index: branches/2.8.x/CHANGELOG
===================================================================
--- branches/2.8.x/CHANGELOG	(revision 1804)
+++ branches/2.8.x/CHANGELOG	(revision 1805)
@@ -13,6 +13,15 @@
 
 
 
+04 Nov-2012 Build 1805 Dietmar Woellbrink (Luisehahne)
+# fixed Undefined variable: nNumRows in \admin\users\index.php
+# fixed Undefined variable: admin in \admin\admintools\tool.php
+! show more information in awaiting activation /admin/users
+! set input passord to autocomplete off /admin/users and /admin/prfeferences
+! add Timezone abbreviation to time format
+! change time and date formats fill with leading zeros
+! optimize REQUEST_METHOD to get page_id and section_id
+! more request vars are possible by this method
 02 Nov-2012 Build 1804 Dietmar Woellbrink (Luisehahne)
 # fixed Illegal string offset 'time' in \framework\SecureForm.mtab.php
 ! add delete Outdated Confirmations in backend
Index: branches/2.8.x/wb/admin/skel/themes/htt/users_form.htt
===================================================================
--- branches/2.8.x/wb/admin/skel/themes/htt/users_form.htt	(revision 1804)
+++ branches/2.8.x/wb/admin/skel/themes/htt/users_form.htt	(revision 1805)
@@ -35,13 +35,13 @@
 <tr>
 	<td class="right">{TEXT_PASSWORD}:</td>
 	<td class="value_input">
-		<input type="password" name="password" maxlength="30" />
+		<input type="password" name="password" value="" maxlength="30" />
 	</td>
 </tr>
 <tr>
 	<td class="right">{TEXT_RETYPE_PASSWORD}:</td>
 	<td class="value_input">
-		<input type="password" name="password2" maxlength="30" />
+		<input type="password" name="password2" value="" maxlength="30" />
 	</td>
 </tr>
 <tr style="{DISPLAY_EXTRA}">
@@ -102,4 +102,15 @@
 
 </form>
 </div>
+<script type="text/javascript">
+<!--
+$(document).ready(function(){
+    var passwordField = $('input[name=password]');
+    passwordField.attr('autocomplete','off');
+    passwordField.val('');
+    var DisplayNameField = $('input[name=display_name]');
+    DisplayNameField.focus();
+});
+-->
+</script>
 <!-- END main_block -->
\ No newline at end of file
Index: branches/2.8.x/wb/admin/skel/themes/htt/preferences.htt
===================================================================
--- branches/2.8.x/wb/admin/skel/themes/htt/preferences.htt	(revision 1804)
+++ branches/2.8.x/wb/admin/skel/themes/htt/preferences.htt	(revision 1805)
@@ -71,4 +71,16 @@
 </div>
 	</fieldset>
 </form>
+<script type="text/javascript">
+<!--
+$(document).ready(function(){
+    var passwordField = $('input[name=password]');
+    passwordField.attr('autocomplete','off');
+    passwordField.val('');
+    var DisplayNameField = $('input[name=display_name]');
+    DisplayNameField.focus();
+});
+-->
+</script>
+
 <!-- END main_block -->
Index: branches/2.8.x/wb/admin/interface/time_formats.php
===================================================================
--- branches/2.8.x/wb/admin/interface/time_formats.php	(revision 1804)
+++ branches/2.8.x/wb/admin/interface/time_formats.php	(revision 1805)
@@ -1,56 +1,57 @@
-<?php
-/**
- *
- * @category        admin
- * @package         interface
- * @author          WebsiteBaker Project
- * @copyright       2004-2009, Ryan Djurovich
- * @copyright       2009-2011, Website Baker Org. e.V.
- * @link            http://www.websitebaker2.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource      $HeadURL$
- * @lastmodified    $Date$
- *
- * Time format list file
- * This file is used to generate a list of time formats for the user to select
- *
- */
-
-if(!defined('WB_URL')) {
-	header('Location: ../../../index.php');
-	exit(0);
-}
-
-// Define that this file is loaded
-if(!defined('TIME_FORMATS_LOADED')) {
-	define('TIME_FORMATS_LOADED', true);
-}
-
-// Create array
-$TIME_FORMATS = array();
-
-// Get the current time (in the users timezone if required)
-$actual_time = time()+ ((isset($user_time) AND $user_time == true) ? TIMEZONE : DEFAULT_TIMEZONE);
-
-// Add values to list
-$TIME_FORMATS['g:i|A'] = gmdate('g:i A', $actual_time);
-$TIME_FORMATS['g:i|a'] = gmdate('g:i a', $actual_time);
-$TIME_FORMATS['H:i:s'] = gmdate('H:i:s', $actual_time);
-$TIME_FORMATS['H:i'] = gmdate('H:i', $actual_time);
-
-// Add "System Default" to list (if we need to)
-if(isset($user_time) AND $user_time == true) {
-	if(isset($TEXT['SYSTEM_DEFAULT'])) {
-		$TIME_FORMATS['system_default'] = gmdate(DEFAULT_TIME_FORMAT, $actual_time).' ('.$TEXT['SYSTEM_DEFAULT'].')';
-	} else {
-		$TIME_FORMATS['system_default'] = gmdate(DEFAULT_TIME_FORMAT, $actual_time).' (System Default)';
-	}
-}
-
-// Reverse array so "System Default" is at the top
-$TIME_FORMATS = array_reverse($TIME_FORMATS, true);
-
-?>
\ No newline at end of file
+<?php
+/**
+ *
+ * @category        admin
+ * @package         interface
+ * @author          Ryan Djurovich (2004-2009),WebsiteBaker Project
+ * @copyright       2009-2012, WebsiteBaker Org. e.V.
+ * @link            http://www.websitebaker2.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$
+ * @filesource      $HeadURL$
+ * @lastmodified    $Date$
+ *
+ * Time format list file
+ * This file is used to generate a list of time formats for the user to select
+ *
+ */
+
+/* -------------------------------------------------------- */
+// Must include code to stop this file being accessed directly
+if(!defined('WB_PATH')) {
+	require_once(dirname(dirname(dirname(__FILE__))).'/framework/globalExceptionHandler.php');
+	throw new IllegalFileException();
+}
+/* -------------------------------------------------------- */
+
+// Define that this file is loaded
+if(!defined('TIME_FORMATS_LOADED')) {
+	define('TIME_FORMATS_LOADED', true);
+}
+
+// Create array
+$TIME_FORMATS = array();
+
+// Get the current time (in the users timezone if required)
+$actual_time = time()+ ((isset($user_time) AND $user_time == true) ? TIMEZONE : DEFAULT_TIMEZONE);
+
+// Add values to list
+$TIME_FORMATS['h:i|A|T'] = gmdate('h:i A T', $actual_time);
+$TIME_FORMATS['h:i|a|T'] = gmdate('h:i a T', $actual_time);
+$TIME_FORMATS['H:i:s|T'] = gmdate('H:i:s T', $actual_time);
+$TIME_FORMATS['H:i|T']   = gmdate('H:i T',   $actual_time);
+
+// Add "System Default" to list (if we need to)
+if(isset($user_time) AND $user_time == true) {
+	if(isset($TEXT['SYSTEM_DEFAULT'])) {
+		$TIME_FORMATS['system_default'] = gmdate(DEFAULT_TIME_FORMAT, $actual_time).' ('.$TEXT['SYSTEM_DEFAULT'].')';
+	} else {
+		$TIME_FORMATS['system_default'] = gmdate(DEFAULT_TIME_FORMAT, $actual_time).' (System Default)';
+	}
+}
+
+// Reverse array so "System Default" is at the top
+$TIME_FORMATS = array_reverse($TIME_FORMATS, true);
+
Index: branches/2.8.x/wb/admin/interface/version.php
===================================================================
--- branches/2.8.x/wb/admin/interface/version.php	(revision 1804)
+++ branches/2.8.x/wb/admin/interface/version.php	(revision 1805)
@@ -51,5 +51,5 @@
 
 // check if defined to avoid errors during installation (redirect to admin panel fails if PHP error/warnings are enabled)
 if(!defined('VERSION')) define('VERSION', '2.8.3');
-if(!defined('REVISION')) define('REVISION', '1804');
+if(!defined('REVISION')) define('REVISION', '1805');
 if(!defined('SP')) define('SP', '');
Index: branches/2.8.x/wb/admin/interface/date_formats.php
===================================================================
--- branches/2.8.x/wb/admin/interface/date_formats.php	(revision 1804)
+++ branches/2.8.x/wb/admin/interface/date_formats.php	(revision 1805)
@@ -1,66 +1,66 @@
-<?php
-/**
- *
- * @category        admin
- * @package         interface
- * @author          WebsiteBaker Project
- * @copyright       2004-2009, Ryan Djurovich
- * @copyright       2009-2011, Website Baker Org. e.V.
- * @link            http://www.websitebaker2.org/
- * @license         http://www.gnu.org/licenses/gpl.html
- * @platform        WebsiteBaker 2.8.x
- * @requirements    PHP 5.2.2 and higher
- * @version         $Id$
- * @filesource      $HeadURL$
- * @lastmodified    $Date$
- *
- * Date format list file
- * This file is used to generate a list of date formats for the user to select
- *
- */
-
-if(!defined('WB_URL')) {
-	header('Location: ../../../index.php');
-	exit(0);
-}
-
-// Define that this file is loaded
-if(!defined('DATE_FORMATS_LOADED')) {
-	define('DATE_FORMATS_LOADED', true);
-}
-
-// Create array
-$DATE_FORMATS = array();
-
-// Get the current time (in the users timezone if required)
-$actual_time = time()+ ((isset($user_time) && $user_time == true) ? TIMEZONE : DEFAULT_TIMEZONE);
-
-// Add values to list
-$DATE_FORMATS['l,|jS|F,|Y'] = gmdate('l, jS F, Y', $actual_time);
-$DATE_FORMATS['jS|F,|Y'] = gmdate('jS F, Y', $actual_time);
-$DATE_FORMATS['d|M|Y'] = gmdate('d M Y', $actual_time);
-$DATE_FORMATS['M|d|Y'] = gmdate('M d Y', $actual_time);
-$DATE_FORMATS['D|M|d,|Y'] = gmdate('D M d, Y', $actual_time);
-$DATE_FORMATS['d-m-Y'] = gmdate('d-m-Y', $actual_time).' (D-M-Y)';
-$DATE_FORMATS['m-d-Y'] = gmdate('m-d-Y', $actual_time).' (M-D-Y)';
-$DATE_FORMATS['d.m.Y'] = gmdate('d.m.Y', $actual_time).' (D.M.Y)';
-$DATE_FORMATS['m.d.Y'] = gmdate('m.d.Y', $actual_time).' (M.D.Y)';
-$DATE_FORMATS['d/m/Y'] = gmdate('d/m/Y', $actual_time).' (D/M/Y)';
-$DATE_FORMATS['m/d/Y'] = gmdate('m/d/Y', $actual_time).' (M/D/Y)';
-$DATE_FORMATS['j.n.Y'] = gmdate('j.n.Y', $actual_time).' (j.n.Y)';
-
-// Add "System Default" to list (if we need to)
-if(isset($user_time) && $user_time == true)
-{
-	if(isset($TEXT['SYSTEM_DEFAULT']))
-	{
-		$DATE_FORMATS['system_default'] = gmdate(DEFAULT_DATE_FORMAT, $actual_time).' ('.$TEXT['SYSTEM_DEFAULT'].')';
-	} else {
-		$DATE_FORMATS['system_default'] = gmdate(DEFAULT_DATE_FORMAT, $actual_time).' (System Default)';
-	}
-}
-
-// Reverse array so "System Default" is at the top
-$DATE_FORMATS = array_reverse($DATE_FORMATS, true);
-
-?>
\ No newline at end of file
+<?php
+/**
+ *
+ * @category        admin
+ * @package         interface
+ * @author          Ryan Djurovich (2004-2009),WebsiteBaker Project
+ * @copyright       2009-2012, WebsiteBaker Org. e.V.
+ * @link            http://www.websitebaker2.org/
+ * @license         http://www.gnu.org/licenses/gpl.html
+ * @platform        WebsiteBaker 2.8.x
+ * @requirements    PHP 5.2.2 and higher
+ * @version         $Id$
+ * @filesource      $HeadURL$
+ * @lastmodified    $Date$
+ *
+ * Date format list file
+ * This file is used to generate a list of date formats for the user to select
+ *
+ */
+
+/* -------------------------------------------------------- */
+// Must include code to stop this file being accessed directly
+if(!defined('WB_PATH')) {
+	require_once(dirname(dirname(dirname(__FILE__))).'/framework/globalExceptionHandler.php');
+	throw new IllegalFileException();
+}
+/* -------------------------------------------------------- */
+
+// Define that this file is loaded
+if(!defined('DATE_FORMATS_LOADED')) {
+	define('DATE_FORMATS_LOADED', true);
+}
+
+// Create array
+$DATE_FORMATS = array();
+
+// Get the current time (in the users timezone if required)
+$actual_time = time()+ ((isset($user_time) && $user_time == true) ? TIMEZONE : DEFAULT_TIMEZONE);
+
+// Add values to list
+$DATE_FORMATS['l,|jS|F,|Y'] = gmdate('l, jS F, Y', $actual_time);
+$DATE_FORMATS['jS|F,|Y']    = gmdate('jS F, Y', $actual_time);
+$DATE_FORMATS['d|M|Y']      = gmdate('d M Y', $actual_time);
+$DATE_FORMATS['M|d|Y']      = gmdate('M d Y', $actual_time);
+$DATE_FORMATS['D|M|d,|Y']   = gmdate('D M d, Y', $actual_time);
+$DATE_FORMATS['d-m-Y']      = gmdate('d-m-Y', $actual_time).' (D-M-Y)';
+$DATE_FORMATS['m-d-Y']      = gmdate('m-d-Y', $actual_time).' (M-D-Y)';
+$DATE_FORMATS['d.m.Y'] = gmdate('d.m.Y', $actual_time).' (D.M.Y)';
+$DATE_FORMATS['m.d.Y'] = gmdate('m.d.Y', $actual_time).' (M.D.Y)';
+$DATE_FORMATS['d/m/Y'] = gmdate('d/m/Y', $actual_time).' (D/M/Y)';
+$DATE_FORMATS['m/d/Y'] = gmdate('m/d/Y', $actual_time).' (M/D/Y)';
+$DATE_FORMATS['j.n.Y'] = gmdate('j.n.Y', $actual_time).' (j.n.Y)';
+
+// Add "System Default" to list (if we need to)
+if(isset($user_time) && $user_time == true)
+{
+	if(isset($TEXT['SYSTEM_DEFAULT']))
+	{
+		$DATE_FORMATS['system_default'] = gmdate(DEFAULT_DATE_FORMAT, $actual_time).' ('.$TEXT['SYSTEM_DEFAULT'].')';
+	} else {
+		$DATE_FORMATS['system_default'] = gmdate(DEFAULT_DATE_FORMAT, $actual_time).' (System Default)';
+	}
+}
+
+// Reverse array so "System Default" is at the top
+$DATE_FORMATS = array_reverse($DATE_FORMATS, true);
Index: branches/2.8.x/wb/admin/users/users.php
===================================================================
--- branches/2.8.x/wb/admin/users/users.php	(revision 1804)
+++ branches/2.8.x/wb/admin/users/users.php	(revision 1805)
@@ -25,11 +25,15 @@
 
 if(!class_exists('admin', false)){ include(WB_PATH.'/framework/class.admin.php'); }
 
+$requestMethod = '_'.strtoupper($_SERVER['REQUEST_METHOD']);
+$aActionRequest = (isset(${$requestMethod})) ? ${$requestMethod} : null;
+
 $action = 'cancel';
+
 // Set parameter 'action' as alternative to javascript mechanism
-$action = (isset($_POST['modify']) ? 'modify' : $action );
-$action = (isset($_POST['delete']) ? 'delete' : $action );
-$action = (isset($_POST['delete_outdated']) ? 'delete_outdated' : $action );
+$action = (isset($aActionRequest['modify']) ? 'modify' : $action );
+$action = (isset($aActionRequest['delete']) ? 'delete' : $action );
+$action = (isset($aActionRequest['delete_outdated']) ? 'delete_outdated' : $action );
 
 switch ($action):
 	case 'modify' :
@@ -189,8 +193,6 @@
 			$template->parse('show_add_loginname', '', true);
 			$template->parse('main', 'main_block', false);
 			$template->pparse('output', 'page');
-			// Print admin footer
-			$admin->print_footer();
 			break;
 		case 'delete' :
 			// Print header
@@ -221,12 +223,9 @@
 			} else {
 				$admin->print_success($MESSAGE['USERS_DELETED']);
 			}
-			// Print admin footer
-			$admin->print_footer();
 			break;
 		case 'delete_outdated' :
 			$admin = new admin('Access', 'users_delete');
-
 			$user_id = intval($admin->checkIDKEY('user_id_activation_id', 0, $_SERVER['REQUEST_METHOD']));
 			// Check if user id is a valid number and doesnt equal 1
 			if($user_id == 0){
@@ -243,11 +242,13 @@
 			} else {
 				$admin->print_success($MESSAGE['USERS_DELETED']);
 			}
-			// Print admin footer
-			$admin->print_footer();
-
-
 			break;
 	default:
 			break;
 endswitch;
+
+
+
+// Print admin footer
+$admin->print_footer();
+
Index: branches/2.8.x/wb/admin/users/index.php
===================================================================
--- branches/2.8.x/wb/admin/users/index.php	(revision 1804)
+++ branches/2.8.x/wb/admin/users/index.php	(revision 1805)
@@ -77,7 +77,7 @@
 	$template->set_var('STATUS', 'class="user-active"' );
 	$template->parse('list', 'list_block', true);
 	// Loop through users
-	while($user = $results->fetchRow()) {
+	while($user = $results->fetchRow(MYSQL_ASSOC)) {
 		$template->set_var('VALUE',$admin->getIDKEY($user['user_id']));
 		$template->set_var('STATUS', ($user['active']==false ? 'class="user-inactive"' : 'class="user-active"') );
 		$template->set_var('NAME', $user['display_name'].' ('.$user['username'].')');
@@ -141,7 +141,7 @@
             	while($aUser = $oRes->fetchRow(MYSQL_ASSOC)) {
             		$template->set_var('VALUE',$admin->getIDKEY($aUser['user_id']));
                		$template->set_var('STATUS', '') ;
-            		$template->set_var('NAME', $aUser['display_name'].' ('.$aUser['username'].')');
+            		$template->set_var('NAME', $aUser['display_name'].' ('.$aUser['username'].')'.' ['.$aUser['email'].']');
             		$template->parse('list_confirmed_activation', 'list_confirmed_activation_block', true);
             	}
             	$template->parse('show_confirmed_activation', 'show_confirmed_activation_block',true);
@@ -148,6 +148,8 @@
             }
         } else { $nNumRows = 0; }
 
+} else {
+$nNumRows = 0;
 }
 
 if ( $nNumRows == 0){
Index: branches/2.8.x/wb/admin/login/index.php
===================================================================
--- branches/2.8.x/wb/admin/login/index.php	(revision 1804)
+++ branches/2.8.x/wb/admin/login/index.php	(revision 1805)
@@ -16,11 +16,12 @@
  */
 
 // Include the configuration file
-if(!defined('WB_URL') && file_exists(realpath('../../config.php'))) {
-    require('../../config.php');
+$config_file = realpath('../../config.php');
+if(file_exists($config_file) && !defined('WB_URL'))
+{
+	require_once($config_file);
 }
 
-//require_once(WB_PATH."/framework/class.login.php");
 if(!class_exists('login', false)){ require_once(WB_PATH.'/framework/class.login.php'); }
 if(!class_exists('frontend', false)){ require_once(WB_PATH.'/framework/class.frontend.php'); }
 
@@ -72,4 +73,3 @@
 					'GROUPS_TABLE' => TABLE_PREFIX."groups",
 			)
 		);
-//$admin->print_footer();
Index: branches/2.8.x/wb/admin/admintools/tool.php
===================================================================
--- branches/2.8.x/wb/admin/admintools/tool.php	(revision 1804)
+++ branches/2.8.x/wb/admin/admintools/tool.php	(revision 1805)
@@ -14,12 +14,23 @@
  * @lastmodified    $Date$
  *
  */
-require('../../config.php');
-require_once(WB_PATH.'/framework/class.admin.php');
+
+$config_file = realpath('../../config.php');
+if(file_exists($config_file) && !defined('WB_URL'))
+{
+	require_once($config_file);
+}
+
+if(!class_exists('admin', false)){
+    include(WB_PATH.'/framework/class.admin.php');
+    $admin = new admin('Admintools','admintools');
+}
+
 require_once(WB_PATH.'/framework/functions.php');
 
-	$toolDir = (isset($_GET['tool']) && (trim($_GET['tool']) != '') ? trim($_GET['tool']) : '');
-	$doSave = (isset($_POST['save_settings']) || (isset($_POST['action']) && strtolower($_POST['action']) == 'save'));
+$toolDir = (isset($_GET['tool']) && (trim($_GET['tool']) != '') ? trim($_GET['tool']) : '');
+$doSave = (isset($_POST['save_settings']) || (isset($_POST['action']) && strtolower($_POST['action']) == 'save'));
+
 // test for valid tool name
 	if(preg_match('/^[a-z][a-z_\-0-9]{2,}$/i', $toolDir)) {
 	// Check if tool is installed
Index: branches/2.8.x/wb/framework/class.admin.php
===================================================================
--- branches/2.8.x/wb/framework/class.admin.php	(revision 1804)
+++ branches/2.8.x/wb/framework/class.admin.php	(revision 1805)
@@ -21,8 +21,10 @@
 	throw new IllegalFileException();
 }
 /* -------------------------------------------------------- */
-require_once(WB_PATH.'/framework/class.wb.php');
 
+// Load the other required class files if they are not already loaded
+if(!class_exists('wb', false)){ include(WB_PATH.'/framework/class.wb.php'); }
+
 // Get WB version
 require_once(ADMIN_PATH.'/interface/version.php');
 
Index: branches/2.8.x/wb/modules/admin.php
===================================================================
--- branches/2.8.x/wb/modules/admin.php	(revision 1804)
+++ branches/2.8.x/wb/modules/admin.php	(revision 1805)
@@ -15,41 +15,35 @@
  *
  */
 
-// Stop this file being access directly
-if(defined('WB_PATH') == false)
-{
-	die('<h2 style="color:red;margin:3em auto;text-align:center;">Cannot access this file directly</h2>');
+/* -------------------------------------------------------- */
+// Must include code to stop this file being accessed directly
+if(!defined('WB_PATH')) {
+	require_once((dirname(dirname(__FILE__))).'/framework/globalExceptionHandler.php');
+	throw new IllegalFileException();
 }
+/* -------------------------------------------------------- */
+// Create new admin object, you can set the next variable in your module
+// to print with or without header, default is with header
+// it is recommed to set the variable before including the /modules/admin.php
+    $admin_header = (!isset($admin_header)) ? true : $admin_header;
+    if(!class_exists('admin', false)){ include(WB_PATH.'/framework/class.admin.php'); }
+    $admin = new admin('Pages', 'pages_modify',(bool)$admin_header);
 
-// Get page id
-	$requestMethod = '_'.strtoupper($_SERVER['REQUEST_METHOD']);
-	$page_id = intval(isset(${$requestMethod}['page_id'])) ? ${$requestMethod}['page_id'] : (isset($page_id) ? intval($page_id) : 0);
-	if(	($page_id == 0)) {
-		header("Location: index.php");
+    $requestMethod = '_'.strtoupper($_SERVER['REQUEST_METHOD']);
+    $aActionRequest = (isset(${$requestMethod})) ? ${$requestMethod} : null;
+
+    $page_id = isset($aActionRequest['page_id']) ? intval($aActionRequest['page_id']) :  (isset($page_id) ? intval($page_id) : 0);
+    $section_id = isset($aActionRequest['section_id']) ? intval($aActionRequest['section_id']) : (isset($section_id) ? intval($section_id) : 0);
+
+	if(	($page_id == 0) ||( $section_id == 0)  ) {
+		$admin->send_header("Location: index.php");
 		exit(0);
 	}
 
-// Get section id if there is one
-	$requestMethod = '_'.strtoupper($_SERVER['REQUEST_METHOD']);
-	$section_id = intval(isset(${$requestMethod}['section_id'])) ? ${$requestMethod}['section_id'] : (isset($section_id) ? intval($section_id) : 0);
-	if(	($section_id == 0) && isset($section_required)) {
-		header("Location: $section_required");
-		exit(0);
-	}
-/*
-// be sure is is numeric
-$page_id = intval($page_id);
-$section_id = intval($section_id);
-*/
 // Create js back link
 // $js_back = 'javascript: history.go(-1);';
 $js_back = ADMIN_URL.'/pages/sections.php?page_id='.$page_id;
-// Create new admin object, you can set the next variable in your module
-// to print with or without header, default is with header
-// it is recommed to set the variable before including the /modules/admin.php
-$admin_header = (!isset($admin_header)) ? true : $admin_header;
-require_once(WB_PATH.'/framework/class.admin.php');
-$admin = new admin('Pages', 'pages_modify',(bool)$admin_header);
+
 // Get perms
 // unset($admin_header);
 
