Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-12-27 01:25:10

jauhari
Member
Registered: 2007-05-24
Posts: 97
Website

I want limit showing time.

Hi All,

I have some question, how to do this.
I have some Image that I call it via Javascript, this image will be show on only on front page, and was working very well. But I want make it more complex.

I want if, some user was visit my site they will store some cookies or something that will remembered by browser so when the current user visit my front page again, the image not show again. And the cookies will keep for 2hours, and after 2hours if current user visit again they will show the image again.

How to do this?

Please help and thanks

Offline

#2 2007-12-27 02:15:20

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: I want limit showing time.

I can’t remember the exact js syntax for this right now but if you do a google search for ‘javascript cookies’ you’ll find lots of examples and library code you can adopt for your cookie handling. Here’s one example, picked at random, from the Google results.


Steve

Offline

#3 2007-12-27 02:19:01

jauhari
Member
Registered: 2007-05-24
Posts: 97
Website

Re: I want limit showing time.

Any feedback?

Offline

Board footer

Powered by FluxBB