View Full Version : pop up window with "don't show again" checkbox

07-29-2009, 09:01 AM
Hi Guys,
I want to create a how to pop up with a checkbox that the user can tick to not show the pop up again so it may need to have a cookie applied to it.
Anybody know how?

Philip M
07-29-2009, 09:57 AM
Well, what you want is something like this in the pop-up

Instructions Here<br><br>

Don't show me these instructions again <input type = "checkbox" name = "chk1" id ="chk1" onclick = "makeCookie()">

Then if the checkbox is checked, set the cookie, and read it back in onload of the main page.

Remember that you need to provide some way of erasing the cookie as otherwise the user cannot change his mind and ask to see the instructions again.

But personally would prefer a simpler system which gives more control to the user:-

Check this box to see the instructions <input type = "checkbox" name - "chk1" id = "chk1" onclick = "showPop()">

<script type = "text/javascript">
function showPop() {
if (document.getElementById("chk1").checked == true) {
// show the pop-up


"I'm such a good lover because I practice a lot on my own." - Woody Allen

07-29-2009, 10:04 AM
Thanks will give it a go.
PS I like the Woody Allen Quote! :thumbsup: