Bobo
03-18-2004, 01:28 AM
I have a small form where I am using a cofirm on the reset button click. For some reason though, the confirm always acts as true. How can I fix that (I already tried if (confirm()) ). Also, how can you make it so you cancel a button click or event like "reset()" (see the *)?
<script>
<!--hide
function CLEARIT() {
var y=confirm('Are you sure you want to clear\?');
if (y='true') {document.g.reset()};
else { * };
}
//-->
</script>
<script>
<!--hide
function CLEARIT() {
var y=confirm('Are you sure you want to clear\?');
if (y='true') {document.g.reset()};
else { * };
}
//-->
</script>