-
Notifications
You must be signed in to change notification settings - Fork 0
Session Class
Justin Campo edited this page Oct 24, 2015
·
1 revision
All interactions with PHP's session should go through this class.
##Direct Calls (magic methods)
// These are buggy / need to be tested + documented more
$c->Session->sample["test"];
$c->Session->sample_multi = "test"; (the _ represents another dimension)
//So the above would update $_SESSION["xesm"]["sample"]["multi"] = "test";
##Update
Normal : $Session->update(array("session" => array("id" => "123")));
Shorthand encoding : session->id=test (slight performance decrease)
##Select
Normal : $Session->select(array("session", "id"));
Shorthand encoding : session_id=test (slight performance decrease)
##Delete
Normal : $Session->select(array("session","id"));
Shorthand encoding : session->id=test (slight performance decrease)
##Other methods
create();
clear();
clear_cookies();
id();