Hey guys, I still don't fully understand isset and sessions. I've looked at websites explaining them but they weren't helping me. So can anyone explain them both maybe with a example? Thanks guys!
~baseball435
Isset and sessions
- Jackolantern
- Posts: 10891
- Joined: Wed Jul 01, 2009 11:00 pm
Re: Isset and sessions
Session variables are variables that are stored on the web server. They help you keep "state" between pages, because typically on a web site, the state of your application is lost between page requests.
Isset() is a function to see if a variable has been set to a value. It returns True if it has been set, or False if it has not been set. It is often used to test Session variables to see if they have been set on another page, because otherwise you would just have to use the session variable you are thinking about and see if you get an error, which is obviously not a good design choice.
Isset() is a function to see if a variable has been set to a value. It returns True if it has been set, or False if it has not been set. It is often used to test Session variables to see if they have been set on another page, because otherwise you would just have to use the session variable you are thinking about and see if you get an error, which is obviously not a good design choice.
The indelible lord of tl;dr
-
Baseball435
- Posts: 548
- Joined: Sun May 30, 2010 3:49 am
Re: Isset and sessions
Oohh okay thanks!