Permalink
Browse files

API CHANGE Removed Session::load_config() (no longer supported)

  • Loading branch information...
1 parent 10dffd3 commit 27fd3e5633af1d88f2237df54a29441b6aaa05f9 @chillu chillu committed Mar 9, 2012
Showing with 0 additions and 26 deletions.
  1. +0 −26 control/Session.php
View
@@ -417,7 +417,6 @@ public static function setFormMessage($formname,$message,$type){
* @param string $sid Start the session with a specific ID
*/
public static function start($sid = null) {
- self::load_config();
$path = self::get_cookie_path();
$domain = self::get_cookie_domain();
$secure = self::get_cookie_secure();
@@ -464,31 +463,6 @@ public static function destroy($removeCookie = true) {
session_destroy();
}
}
-
- /**
- * Use the Session::$session_ips array to set timeouts based on IP address or IP address
- * range.
- *
- * Note: The use of _sessions.php is deprecated.
- */
- public static function load_config() {
- foreach(self::$session_ips as $sessionIP => $timeout) {
- if(preg_match('/^([0-9.]+)\s?-\s?([0-9.]+)$/', $sessionIP, $ips)) {
- if(isset($_SERVER['REMOTE_ADDR'])) {
- $startIP = ip2long($ips[1]);
- $endIP = ip2long($ips[2]);
- $clientIP = ip2long($_SERVER['REMOTE_ADDR']);
- $minIP = min($startIP, $endIP);
- $maxIP = max($startIP, $endIP);
-
- if($minIP <= $clientIP && $clientIP <= $maxIP) {
- return self::set_timeout($timeout);
- }
- }
- }
- // TODO - Net masks or something
- }
- }
/**
* Set the timeout of a Session value

0 comments on commit 27fd3e5

Please sign in to comment.