Session, some fixes in PagerView and ErrorView #16
git-svn-id: svn+ssh://code.netmonsters.ru/svn/majestic/branches/evo@126 4cb57b5f-5bbd-dd11-951b-001d605cbbc5
This commit is contained in:
@ -64,28 +64,6 @@ class Env
|
||||
return (isset($_SERVER[$key])) ? $_SERVER[$key] : $default;
|
||||
}
|
||||
|
||||
static public function Session($var, $default = false)
|
||||
{
|
||||
return isset($_SESSION[$var]) ? $_SESSION[$var] : $default;
|
||||
}
|
||||
|
||||
static public function setSession($var, $value)
|
||||
{
|
||||
$_SESSION[$var] = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Unsets session var
|
||||
*
|
||||
* @param string $var
|
||||
*/
|
||||
static public function unsetSession($var)
|
||||
{
|
||||
if (isset($_SESSION[$var])) {
|
||||
unset($_SESSION[$var]);
|
||||
}
|
||||
}
|
||||
|
||||
static public function setCookie($var, $value, $time = 0, $path = '/')
|
||||
{
|
||||
return setcookie($var, $value, $time, $path);
|
||||
@ -120,5 +98,4 @@ class Env
|
||||
{
|
||||
self::$params = self::$params + $params;
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user