[thelist] Two submit buttons
Ken Schaefer
ken at adOpenStatic.com
Sun Nov 30 05:52:17 CST 2003
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "David Travis" <dwork at macam.ac.il>
Subject: [thelist] Two submit buttons
: If I have more than one submit button (input type=submit), is it
: possible to know which button was clicked, when I parse the
: posted data server side? I don't care which server technology
: (PHP, ASP, ASP.NET), I just wonder if it is possible.
:
: If yes, I believe it depends on the browser, though I am
: not sure.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The name/value pair for input buttons is sent by the browser.
You can see this by changing the method from post to get. Or have a look at
a site like google.com
http://www.google.com/search?q=button&btnG=Google+Search
(this is a search for "button"). Note the btnG=Google+Search?
So, you could even give them the same name, but different values, or
different names and the same value, or different names and different values.
Cheers
Ken
Microsoft MVP - Windows Server (IIS)
More information about the thelist
mailing list