Results 1 to 2 of 2

Thread: Cancel Submit with Button

  1. #1
    Join Date
    Apr 2010

    Question Cancel Submit with Button

    Hi guys,

    I have a question or an issue.

    I would like to cancel a submit from muy submit-next button. The event starts from this input:

    <input type=submit name=ClickedButton value='Siguiente>>' class='nextButton'>

    And I would like to append something like onClick="checkPrec();" on this input.

    I have read thatI have to add on the <form> tag somthing like this:

    <form name="form" id="form" method='post' onSubmit="return checkPrec();">

    But I really need to do it from the button OnClick event.

    Du you have any idea how to make that possible? Is that possible?

    Thank you in advance.

  2. #2
    Join Date
    Apr 2003
    Either way would work using return checkPrec();
    I always prefer to use onsubmit in the form tag.
    At least 98% of internet users' DNA is identical to that of chimpanzees

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center