Script To Execute Client Side Once Per Session

Discussion in 'PHP' started by 2blind2c#, Jan 10, 2008.

  1. #1
    Like, if I want to display something like a HTML element, or execute some javascript I want to know how to like, only have it execute to where once a visitor arrives to my website, it'll only execute once a day/hour/30 mins for that visitor since I don't want to say... execute some JS for a popover for every page that user goes to & overburdening them to leave.
    So any help in this matter of doing this via PHP server function would be greatly appreciated :D
     
    2blind2c#, Jan 10, 2008 IP
  2. Kieran.in

    Kieran.in Peon

    Messages:
    22
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Set a cookie. The easiest way would be to set a cookie with an expiry time, and when they visit your site without the cookie show the popup.

    Not the best way, but the easiest way.
     
    Kieran.in, Jan 10, 2008 IP