![]() |
proper use of two conditions in using sessions? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: proper use of two conditions in using sessions? (/showthread.php?tid=7296) |
proper use of two conditions in using sessions? - El Forum - 04-02-2008 [eluser]new_igniter[/eluser] Hello, Can anyone tell me the right syntax for using two conditions (in an if statement) while using CI sessions? I tried: if ($this->session->userdata('stat') != "OK" && $this->session->userdata('name') != "fred") { do something } this doesnt work and throws errors. My apologies in advance for being dumb. proper use of two conditions in using sessions? - El Forum - 04-02-2008 [eluser]GSV Sleeper Service[/eluser] that looks ok to me, what error do you get? proper use of two conditions in using sessions? - El Forum - 04-02-2008 [eluser]new_igniter[/eluser] I was being careless. It was something else! My bad, thanks Sleeper!!! |