Click to See Complete Forum and Search --> : Popups
newguy
01-22-2004, 08:55 AM
Hi,
I need to have a popup which will ask for confirmation that the user has read the contents before allowing them to continue. Any ideas?
Cheers
chriz
01-22-2004, 08:59 AM
Try this
<!-- in the head tags -->
<script language="javascript">
function go() {
if(confirm("Have you read the terms?")) {
window.location.href="okgothrough.htm"
}else
{
window.location.href="noway.htm"
}
}
</script>
<!-- and put this in the body tags -->
<body onLoad="go()">
</body></html>
Please check out my site
www.freewebs.com/chrisa2003
olerag
01-22-2004, 09:01 AM
Use the "window.opener" function in your child window to
communicate back to your parent window if the agreement
has or has not been confirmed. Then you may close the
child if desired.
This forum has multiple threads for this usage with
code samples. You can use the "search" tool to obtain
those threads.
newguy
01-22-2004, 10:28 AM
Thanks guys, although I need a bit more. Here is what I'm trying to do:
I have a site where I have several pages, each of which require that terms and conditions have been read before proceeding to the page. Once the T & C's have been agreed to, the visitor can then look at any and all of these pages during that session. A new session will require the visitor to agree to the T & C's again.
HELP!!!!!!!!!
TheBearMay
01-22-2004, 11:44 AM
Sounds like a good job for a cookie...