views:

36

answers:

1

Hello all. I am trying to create a popup ad with a custom lightbox feel and I can get the popup to work, but it is not setting the cookie. Any ideas on what this could be? Since the code is so long, I am posting it as a GitHub Gist here: http://gist.github.com/501348

Thanks in advance all, Josh

A: 

Hello Josh,

I don't know if what I am going to say will help, but it works for me.

I put an alert after the cookie set on line 16 in your code and it set to shown. I put an alert after line 29 and it hit (when I closed and opened a fresh browser). Once hit the browser kepts returning "shown".

This was the jQuery cookie plugin I used, I am guessing it is the same as the one you used.

Just going to ask a few "are you sure" style question so apologies:

1) Do you have JavaScript enabled?

2) Are you sure your script isn't erroring? When running in IE all the console calls are invalid and will return as errors (breaking the javascript), try commenting those lines out.

Cheers

Luke Duddridge
Will do. Yes, I am using that plugin. Yes, JavaScript is enabled. I don't use IE. But, I did try it in IE and found out console.* does not work. So I commented it out and it sort of worked. I will try using the alert on those lines. Will reply soon! Thanks
Josh Brown