Accept terms and conditions script

Hi all,

I found a script that will do this but I’m wondering if there is a way to modify it so that it makes the user confirm once more that they accept. Maybe have another alert that asks them:

Please choose OK to accept the terms or Cancel to exit.

Can this be added?

<SCRIPT language=JavaScript>

//Accept terms & conditions script (by InsightEye
//Visit JavaScript Kit ( for this script & more.

function checkCheckBox(f){
if (f.agree.checked == false )
alert('Please check the box to continue.');
return false;
return true;

<form action="/yourscript.cgi-or-your-page.html" method="GET" onsubmit="return checkCheckBox(this)">

<!--Enter your form contents here-->

<b>By submitting, I agree that all info entered was done accurately & truthfully.</b><br>
I accept: <input type="checkbox" value="0" name="agree">
<input type="submit" value="Submit form">
<input type="button" value="Exit" onclick="document.location.href='/index.html';">

Hi Ash. :slight_smile:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"

<script type="text/javascript">

function affirmData(oForm)
	var oCheckbox = oForm.elements.agree;
	if (oCheckbox.checked)
		var OK = confirm('Please confirm: all information entered is accurate.\
Thank you.');
		if (!OK)
			return (oCheckbox.checked = false);
		alert('Please check the "agreement" box to continue.');
		return false;

<form action="javascript&#58;alert('ok')" method="get" onsubmit="return affirmData(this)">

<!--Enter your form contents here-->

<b>By submitting, I affirm that all information entered is accurate & truthful.</b>
<br /><br />
You betcha. Agreed. <input type="checkbox" name="agree" value="1" />
<br /><br />
<input type="submit" value="Submit" />
<input type="button" value="Exit" onclick="self.location='/index.html'" />

Hi Adios. This couldn’t be more ideal, thanks! :slight_smile: