Page 1 of 1
making php constantly check for session
Posted: Thu Jul 19, 2007 4:25 pm
by suthie
I am using iframes in a website i am making, and i want the page to know what is going on within the iframe by using a session.
how can i make the page constantly check a session to see if you are logged in and then either display "you are not logged in" or "you are logged in as username" ?
Posted: Thu Jul 19, 2007 4:34 pm
by guitarlvr
AJAX might be able to do that. Why do you want to check constantly? Usually someone is only going to be able to do so something if the page is either refreshed or a request for a different page has been made. If those two are the case, you can check if they are logged in at that point. I wouldn't think checking constantly would be good for performance or reliability.
Posted: Thu Jul 19, 2007 4:39 pm
by suthie
i just need the session variables to always be up to date. these variables will only change when stuff goes on inside the iframe.
i guess what i am asking for is probably not the best way to make this happen.
what i still need is for the page to refresh if the session ends. how can i do that?