Take the 2-minute tour ×  If i uncomment this code, i get blank
page at site. If i comment this, site works. Here is my exit
code (auth by sessions):      function exit($action='') {     if
($action == "true") {         echo "Exit.";     $login =
$this->session->userdata('username');     if ($login == NULL) {
redirect('/blog/login/', 'location', '301');     $array_itmes =
array('username' => "$login");     redirect('/blog/exit/true/',
'location', '301');}  after normal login:      $newdata =
array('username' => "$name");  in other actions i using:      if
($login !== NULL) {         echo $login;  and I get my username.
where is an error in first code? i`m from Russia, so sorry for
bad English.  share|improve this question Not sure if I'm
following you 100% which is why I can't answer your question,
but defining a method called 'exit' might be problematic, since
it's a reserved word for PHP. Try renaming it and see if that
changes anything. –  polarblau Mar 19 '11 at 21:23 add comment
2 Answers  up vo