in reply to two submit buttons in a form
or maybe, you can use a radio button (like the ones for the voting system here) and one submit.
and later on...<input type="text" value="" name="buddyname"><br> <input type="radio" name="action" value="add"> Add Buddy <br> <input type="radio" name="action" value="remove"> Add Buddy <br>
my $action = $q->param('action'); # this is assuming you're using CGI. +pm; if ($action eq 'add') { &addBuddy; else { &deleteBuddy; }
As far as I can see, this is way better than two submits.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: two submit buttons in a form
by turnstep (Parson) on Mar 12, 2001 at 19:38 UTC |