语法 onSubmit="handlerText" 参数
安全性 Navigator 4.0: Submitting a form to a mailto: or news: URL requires the UniversalSendMail privilege. 要获取 Navigator 4.0 中关于安全性更多的信息,请看“JavaScript 指南”中的第七章“JavaScript 安全性”。 描述 You can use onSubmit to prevent a form from being submitted; to do so, put a return statement that returns false in the event handler. Any other returned value lets the form submit. If you omit the return statement, the form is submitted. 使用的事件属性
示例 In the following example, onSubmit calls the validate function to evaluate the data being submitted. If the data is valid, the form is submitted; otherwise, the form is not submitted. <FORM onSubmit="return validate(this)">...</FORM> See also the示例 for Form.
参看 Submit, Form.submit
要获得关于事件句柄的常规信息,请看“事件的常规信息”。
要获得关于事件对象的信息,请看事件。
返回页面顶部