How to make javascript only take effect once per browser session

Discussion in 'HTML & Website Design' started by se_p800, Apr 21, 2008.

  1. #1
    Ok bare with me i am new to html. I posted a similar thread but realised I was asking the wrong thing so I thought it best to start again.

    The javascript I am using is called modalbox. In order for it to work you have to add the neccessary files to your server and paste this code into your pages:
    I have got everything working fine except I only want this script to take effect once per browser session as shown here

    I have tried addingg this after the code:

    As from what I can tell from the source code on the website I just listed that is what they have used, but I am having no luck. Is anybody able to modify the code I have pasted to make it only take effect once per browser session? If so I would be so appreciative. Thanks
     
    se_p800, Apr 21, 2008 IP
  2. se_p800

    se_p800 Well-Known Member

    Messages:
    609
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    128
    Digital Goods:
    2
    #2
    Can anyone help me please?
     
    se_p800, Apr 23, 2008 IP
  3. se_p800

    se_p800 Well-Known Member

    Messages:
    609
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    128
    Digital Goods:
    2
    #3
    Ok I found out that I have to send a cookie that expires in 24 hours. How would I do this? Thanks
     
    se_p800, Apr 24, 2008 IP