mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-14 01:34:55 +02:00
* new configurable: session_prefix, to allow more websites on one machine
* must be unique for every website on your dedicated server!
This commit is contained in:
@@ -943,6 +943,19 @@ function str_replace_first($search, $replace, $subject) {
|
||||
return $subject;
|
||||
}
|
||||
|
||||
function setSession($key, $data) {
|
||||
global $config;
|
||||
$_SESSION[$config['session_prefix'] . $key] = $data;
|
||||
}
|
||||
function getSession($key) {
|
||||
global $config;
|
||||
return (isset($_SESSION[$config['session_prefix'] . $key])) ? $_SESSION[$config['session_prefix'] . $key] : false;
|
||||
}
|
||||
function unsetSession($key) {
|
||||
global $config;
|
||||
unset($_SESSION[$config['session_prefix'] . $key]);
|
||||
}
|
||||
|
||||
// validator functions
|
||||
require_once(LIBS . 'validator.php');
|
||||
?>
|
||||
|
Reference in New Issue
Block a user