Grow your CSS skills. Land your dream job.

Refresh Pages on Session Destroy

  • # July 8, 2012 at 11:34 pm

    I want to refresh all pages if my session is destroyed from any of the page by clicking log-out.

    # July 9, 2012 at 4:52 am

    Maybe something like this:

    header("Location: ".$_SERVER);

    $_SERVER = this is to complete the address,

    If your address is http://www.mypageiscool.com/page.php

    $_SERVER = page.php

    $_SERVER = http://www.mypageiscool.com/

    # July 9, 2012 at 5:03 am

    One simple option I can think of is doing a simple AJAX request every 5-20 seconds that would check the session and return false or something if it’s destroyed, you can then refresh the page via jQuery.

    # July 15, 2012 at 4:22 am

    @chrisxClash:- Can You help me to give the demo of what you have told

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".