Announcement

Collapse
No announcement yet.

How to do this with a javascript?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to do this with a javascript?

    Code:
    <HTML>
    <script language="javascript">
    function confirmaction(theform) {
    	if (theform.blaat.value=="0") { // I need the correct if statement
    		return false;
    	} else {
    		return confirm("WARNING:\n\nYou're about say BLEH!\n\nAre you SURE?");
    	}
    }
    </script>
    
    <form onSubmit="return confirmaction(this)" action="gayness"  name="blah" method="post">
    <p>Yes<input type='radio' name='blaat' value='1' > No <input type='radio' name='blaat' value='0' checked></p>
    <input type="submit" value="BLeH!">
    </HTML>
    Can anyone help me?

  • #2
    never mind. Did it with onclick

    Comment

    widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
    Working...
    X