Skip to content

Instantly share code, notes, and snippets.

@nixon1333
Last active August 29, 2015 14:05
Show Gist options
  • Save nixon1333/a708ad56e18f084e2deb to your computer and use it in GitHub Desktop.
Save nixon1333/a708ad56e18f084e2deb to your computer and use it in GitHub Desktop.
basic session usage in php strom
//check a session
if ($this->session->has("loggedIn")) {
//remove a session varaiable
$this->session->remove("loggedIn");
}else{
//add a session variable
$this->session->set("loggedIn", '1');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment