]> git.mxchange.org Git - mailer.git/commitdiff
inc/session.php is no longer needed.
authorRoland Haeder <roland@mxchange.org>
Thu, 17 Apr 2014 21:59:21 +0000 (23:59 +0200)
committerRoland Haeder <roland@mxchange.org>
Thu, 17 Apr 2014 21:59:21 +0000 (23:59 +0200)
Signed-off-by: Roland Häder <roland@mxchange.org>
inc/filter-functions.php
inc/filters.php
inc/mysql-connect.php
inc/session-functions.php
inc/session.php

index c8e74588e557eda94cd2b8fa00c2b1af6c793def..939cd84d5b864c2fe88aa943b0adc55915b74caf 100644 (file)
@@ -101,6 +101,7 @@ ORDER BY
        registerFilter(__FUNCTION__, __LINE__, 'init', 'LOAD_CONFIGURATION');
        registerFilter(__FUNCTION__, __LINE__, 'init', 'INIT_RANDOMIZER');
        registerFilter(__FUNCTION__, __LINE__, 'init', 'LOAD_RUNTIME_INCLUDES');
+       registerFilter(__FUNCTION__, __LINE__, 'init', 'INIT_LANGUAGE');
        registerFilter(__FUNCTION__, __LINE__, 'init', 'INIT_EXTENSIONS');
        registerFilter(__FUNCTION__, __LINE__, 'init', 'INIT_SESSION');
        registerFilter(__FUNCTION__, __LINE__, 'init', 'SET_CURRENT_DATE');
index 5b3c05c5f22881e64f1e4b9eec831bbbe2ad0921..0cd2a06191ca317ca8b1ce69434ff214c6bc5cfb 100644 (file)
@@ -880,12 +880,18 @@ function FILTER_RUN_YEARLY_RESET () {
 // Filter for loading more runtime includes (not for installation)
 function FILTER_LOAD_RUNTIME_INCLUDES () {
        // Load more includes
-       foreach (array('databases', 'session') as $inc) {
+       foreach (array('databases') as $inc) {
                // Load the include
                loadIncludeOnce('inc/' . $inc . '.php');
        } // END - foreach
 }
 
+// Filter for initializing language by loading the language file
+function FILTER_INIT_LANGUAGE () {
+       // Load language file(s)
+       loadLanguageFile();
+}
+
 // Filter for checking admin ACL
 function FILTER_CHECK_ADMIN_ACL () {
        // Extension not installed so it's always allowed to access everywhere!
index 4a6361853e92a1480f7e6a8076da478874657d1a..3514b82a4b5cab5e7796fdc1456a14307f497b25 100644 (file)
@@ -132,8 +132,11 @@ if ((!isInstaller()) && (isInstalled())) {
        // Init message system
        initMessages();
 
+       // Init session
+       initSession();
+
        // Include more
-       foreach (array('databases', 'session', 'install-functions', 'load_config', 'load_cache') as $inc) {
+       foreach (array('databases', 'install-functions', 'load_config', 'load_cache') as $inc) {
                // Load include file
                loadIncludeOnce('inc/' . $inc . '.php');
        } // END - foreach
index 954d233c3da5dbf2103694d1588268cea44f26b2..8f2ec9e9ec6c8da9a6fa731dff6309d6f74024cf 100644 (file)
@@ -184,5 +184,28 @@ function isSessionDataSet ($sessionData) {
        return $isset;
 }
 
+// Initializes session
+function initSession () {
+       //* NOISY-DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'CALLED!');
+
+       // Is ext-sql_patches there and newer?
+       if (isExtensionInstalledAndNewer('sql_patches', '0.5.3')) {
+               // Set session save path if set
+               if ((isConfigEntrySet('session_save_path')) && (getConfig('session_save_path') != '')) {
+                       // Please make sure this valid!
+                       session_save_path(getConfig('session_save_path'));
+               } // END - if
+       } // END - if
+
+       // Is a session id there?
+       if (!isValidSession()) {
+               // Start the session
+               $GLOBALS['valid_session']  = session_start();
+               $GLOBALS['isValidSession'] = TRUE;
+       } // END - if
+
+       //* NOISY-DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'EXIT!');
+}
+
 // [EOF]
 ?>
index 355d77307ae34aeb4b7a6649782b5b9ac78f71a6..f551ef47b7591c74e7b59193e56a1fa6505a87ab 100644 (file)
@@ -1,63 +1,3 @@
 <?php
-/************************************************************************
- * Mailer v0.2.1-FINAL                                Start: 09/16/2004 *
- * ===================                          Last change: 11/23/2004 *
- *                                                                      *
- * -------------------------------------------------------------------- *
- * File              : session.php                                      *
- * -------------------------------------------------------------------- *
- * Short description : Session management                               *
- * -------------------------------------------------------------------- *
- * Kurzbeschreibung  : Sitzungs-Management                              *
- * -------------------------------------------------------------------- *
- * $Revision::                                                        $ *
- * $Date::                                                            $ *
- * $Tag:: 0.2.1-FINAL                                                 $ *
- * $Author::                                                          $ *
- * -------------------------------------------------------------------- *
- * Copyright (c) 2003 - 2009 by Roland Haeder                           *
- * Copyright (c) 2009 - 2013 by Mailer Developer Team                   *
- * 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 *
- * the Free Software Foundation; either version 2 of the License, or    *
- * (at your option) any later version.                                  *
- *                                                                      *
- * This program is distributed in the hope that it will be useful,      *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
- * GNU General Public License for more details.                         *
- *                                                                      *
- * You should have received a copy of the GNU General Public License    *
- * along with this program; if not, write to the Free Software          *
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
- * MA  02110-1301  USA                                                  *
- ************************************************************************/
-
-// Some security stuff...
-if (!defined('__SECURITY')) {
-       exit();
-} // END - if
-
-// Is ext-sql_patches there and newer?
-if (isExtensionInstalledAndNewer('sql_patches', '0.5.3')) {
-       // Set session save path if set
-       if ((isConfigEntrySet('session_save_path')) && (getConfig('session_save_path') != '')) {
-               // Please make sure this valid!
-               session_save_path(getConfig('session_save_path'));
-       } // END - if
-} // END - if
-
-// Is a session id there?
-if (!isValidSession()) {
-       // Start the session
-       $GLOBALS['valid_session']  = session_start();
-       $GLOBALS['isValidSession'] = TRUE;
-} // END - if
-
-// Load language file(s)
-loadLanguageFile();
-
-// [EOF]
+// @DEPRECATED
 ?>