in reply to Re: JavaScript and form submission
in thread JavaScript and form submission

Then how do I tell the difference between the Submit and Cancel buttons?

Replies are listed 'Best First'.
Re^3: JavaScript and form submission
by Corion (Patriarch) on Nov 21, 2006 at 14:56 UTC

    If you can use Javascript, just set the value of the hidden field accordingly. If you're supporting non-Javascript too, make the "cancel" link a GET request instead of a button.

      if you can use JavaScript

      It is more important if your users can use JS. Since you usually don't know, systems should be designed so they are still functional if JS isn't available.