开发者

onLoad Pop Up (Load only with the First Visit)

I am Using Colorbox as a Pop Up with a Chat Button that appears.

How Can I make it so it only Pops up on the users 1st visit to the page? Or Maybe it Pops up every 3 Visits?

Here is the Page I am Testing wit开发者_运维百科h: http://www.702wedding.com/weddings-in-las-vegas-pop.asp

Thanks Very Much Community of Wise People.


Use a cookie. This guide should provide you with the information you need on how to store and retrieve cookies.

So you could check if the cookie exists, and if it doesn't, pop up whatever you need. You can store a number in the cookie to tell how many visits have occurred. Then use the % operator to check for every 3rd visit (e.g. if (visits % 3 == 0) { alert('hi'); }.


You need to remember the fact that there was a previous visit. Use a cookie.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜