Script works with IE, but not with Mozilla.. Any suggestions

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
pistolfire99
Forum Commoner
Posts: 58
Joined: Thu May 23, 2002 3:18 pm

Script works with IE, but not with Mozilla.. Any suggestions

Post by pistolfire99 »

Hey guys, this is the URL

http://www.i2l2.com/temp/javascript.html

The scripts works with IE but not with Mozilla 1.2.1. Any suggestion or workarounds on this.

Thank You.
onestop
Forum Newbie
Posts: 5
Joined: Mon Dec 16, 2002 4:45 am

Post by onestop »

Hi

Try changing your script to

<SCRIPT LANGUAGE="JavaScript">
function checkCheckBox(f){
if (!document.checkform.agree.checked || !document.checkform.agree2.checked)
{
alert('Please check the box to continue');
return false;
}else
return true;
}
</script>


Andy

http://www.webdevtips.co.uk
pistolfire99
Forum Commoner
Posts: 58
Joined: Thu May 23, 2002 3:18 pm

Post by pistolfire99 »

Hey, thank you for your reply but I figured it out. Did the same thing as u, just a lil differently in the if-then logic

Code: Select all

<SCRIPT LANGUAGE="JavaScript">
function checkCheckBox()&#123;
if ((document.checkform.agree.checked ) && (document.checkform.agree2.checked))
&#123;
return true;
&#125;else
alert('Please Agree to the terms before continuing');
return false;
&#125;
</script>
Thanks again for replying though.
Post Reply