doorbreaker
Programmer
Hi,
How do I put an else statement in??
I want to check if a field is blank, if it is then ask the user to fill it in.
If it is filled in then ask them to check that it is correct...
Thanks
Chris
Code Below:
if (document.frm.value=='')
{
alert ('Please enter all personalisation text');
document.frm.focus();
return false;
}
var answer = confirm ("Is the personalisation text for your order correct?\n\nIf YES, then please click OK to proceed to our Secure Server\n\nIf NO, then please click CANCEL to re-enter your text")
if (answer)
document.frm.action='order_ends.asp'
else
return false;
How do I put an else statement in??
I want to check if a field is blank, if it is then ask the user to fill it in.
If it is filled in then ask them to check that it is correct...
Thanks
Chris
Code Below:
if (document.frm.value=='')
{
alert ('Please enter all personalisation text');
document.frm.focus();
return false;
}
var answer = confirm ("Is the personalisation text for your order correct?\n\nIf YES, then please click OK to proceed to our Secure Server\n\nIf NO, then please click CANCEL to re-enter your text")
if (answer)
document.frm.action='order_ends.asp'
else
return false;