Skip to main content
November 4, 2010
Answered

Clear cache and session variables

  • November 4, 2010
  • 1 reply
  • 615 views

If I write code on the home page of a website to clear the users cache whenver they navigate to it, will it clear any session variables that where set within the site? What I want to do is make sure the users cache is cleared when they first get to the site. Within the site, there are different places t  login in which session variables are set for the user. If this is done and the user then navigates back to the home page, will their session variables be lost? If so,can anyone suggest a good work around for this.

Thanks

    This topic has been closed for replies.
    Correct answer Owainnorth

    Sessions are tracked using cookies, so as long as you don't delete their cookies they'll remain logged in.

    If in any doubt: try it!

    1 reply

    Owainnorth
    OwainnorthCorrect answer
    Inspiring
    November 4, 2010

    Sessions are tracked using cookies, so as long as you don't delete their cookies they'll remain logged in.

    If in any doubt: try it!