Permalink
Browse files

Remove deprecated session code (taken from oscparky)

  • Loading branch information...
1 parent 10efb0c commit 78de73a7d4d6b9f33009b3f9b2162c8e813e1eab @acidvertigo acidvertigo committed Dec 30, 2011
Showing with 2 additions and 25 deletions.
  1. +2 −13 catalog/admin/includes/functions/sessions.php
  2. +0 −12 catalog/includes/functions/sessions.php
@@ -102,34 +102,23 @@ function tep_session_start() {
}
function tep_session_register($variable) {
- if (PHP_VERSION < 4.3) {
- return session_register($variable);
- } else {
if (isset($GLOBALS[$variable])) {
$_SESSION[$variable] =& $GLOBALS[$variable];
} else {
$_SESSION[$variable] = null;
}
- }
return false;
}
function tep_session_is_registered($variable) {
- if (PHP_VERSION < 4.3) {
- return session_is_registered($variable);
- } else {
- return isset($_SESSION) && array_key_exists($variable, $_SESSION);
+ return isset($_SESSION) && array_key_exists($variable, $_SESSION);
}
- }
+
function tep_session_unregister($variable) {
- if (PHP_VERSION < 4.3) {
- return session_unregister($variable);
- } else {
unset($_SESSION[$variable]);
}
- }
function tep_session_id($sessid = '') {
if ($sessid != '') {
@@ -106,35 +106,23 @@ function tep_session_register($variable) {
global $session_started;
if ($session_started == true) {
- if (PHP_VERSION < 4.3) {
- return session_register($variable);
- } else {
if (isset($GLOBALS[$variable])) {
$_SESSION[$variable] =& $GLOBALS[$variable];
} else {
$_SESSION[$variable] = null;
}
}
- }
return false;
}
function tep_session_is_registered($variable) {
- if (PHP_VERSION < 4.3) {
- return session_is_registered($variable);
- } else {
return isset($_SESSION) && array_key_exists($variable, $_SESSION);
}
- }
function tep_session_unregister($variable) {
- if (PHP_VERSION < 4.3) {
- return session_unregister($variable);
- } else {
unset($_SESSION[$variable]);
}
- }
function tep_session_id($sessid = '') {
if (!empty($sessid)) {

0 comments on commit 78de73a

Please sign in to comment.