Code

Upated sieveMangement list. Firt icon wasn't displayed
[gosa.git] / gosa-core / html / main.php
index c6097168789628f1eb14dd7012f9617651d5bfa8..33da6744814e1b0fbb3be9d18e4481188afb2a7d 100644 (file)
@@ -35,7 +35,6 @@ bindtextdomain($domain, "$BASE_DIR/locale");
 textdomain($domain);
 
 /* Remember everything we did after the last click */
-restore_error_handler();
 session::start();
 session::set('limit_exceeded',FALSE);
 
@@ -85,7 +84,7 @@ if(session::get('_LAST_PAGE_REQUEST') == ""){
    * kill session
    */
   if($request_time > $max_life){
-    session_unset();
+    session::destroy();
     new log("security","login","",array(),"main.php called without session - logging out") ;
     header ("Location: logout.php");
     exit;
@@ -122,7 +121,7 @@ if(session::get('Last_init_lang',$lang)){
 session::set('Last_init_lang',$lang);
 
 /* Preset current main base */
-if(session::is_set('CurrentMainBase')){
+if(!session::is_set('CurrentMainBase')){
   session::set('CurrentMainBase',get_base_from_people($ui->dn));
 }
 
@@ -139,7 +138,7 @@ textdomain($domain);
 @DEBUG (DEBUG_TRACE, __LINE__, __FUNCTION__, __FILE__, $lang, "Setting language to");
 
 /* Prepare plugin list */
-if (session::is_set('plist')){
+if (!session::is_set('plist')){
   /* Initially load all classes */
   $class_list= get_declared_classes();
   foreach ($class_mapping as $class => $path){
@@ -161,7 +160,7 @@ $plist= session::get('plist');
 if (isset($global_check) && $config->data['MAIN']['FORCEGLOBALS'] == 'true'){
   echo _("FATAL: Register globals is on. GOsa will refuse to login unless this is fixed by an administrator.");
   new log("security","login","",array(),"Register globals is on. For security reasons, this should be turned off.") ;
-  session_destroy ();
+  session::destroy ();
   exit ();
 }
 
@@ -247,7 +246,7 @@ if (isset($_GET['reset'])){
   }
 }
 
-/* Install eGOsa hooks, convert _POST to _SESSION['POST'] */
+/* Install eGOsa hooks, convert _POST to session */
 if(isset($_GET['explorer'])){
   session::set('eGosa',TRUE);
 }
@@ -311,7 +310,7 @@ if ($_SERVER["REQUEST_METHOD"] == "POST"){
         $_POST[$name] = $value;
       } 
     }
-    sess_del ('dn');
+    session::un_set ('dn');
   }
 
 
@@ -323,7 +322,7 @@ if ($_SERVER["REQUEST_METHOD"] == "POST"){
       $smarty->display(get_template_path('conflict.tpl'));
       exit ();
     }
-    session::set('session_cnt',$_SESSION['session_cnt'] + 1);
+    session::set('session_cnt', (session::get('session_cnt') + 1));
     session::set('post_cnt' , validate($_POST['session_cnt']) + 1);
   }
 }