[thelist] Javascript: OK? Cancel!
Ben Phillips
ben at inchima.com
Thu Feb 14 05:44:00 CST 2002
> Dunno if this can be done - I want to pop up a javascript alert with
> an 'OK' and 'Cancel' button. Of course the cancel button lets the
> page just kinda sit there, whereas 'OK' proceeds to submit the form.
>
> I know the functionality is doable - but is the dialogue box?
do you mean this?
===========================
function checkOK()
{
var ok=confirm("Are you sure you wish to continue?");
if (ok)
return true;
else
return false;
}
==== and the form button ==
<input type="submit" name="Submit" value=">> send mail"
onClick="return checkOK()">
===========================
benji
inchima.com
More information about the thelist
mailing list