Re: form and php

From: Date: Tue, 27 Mar 2001 18:51:56 +0000
Subject: Re: form and php
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-45758@lists.php.net to get a copy of this message
Hi Augusto, Submit buttons aren't that special, they just send a name=value pair. Doing something like this : If the following is pressed, if ($action == 'edit') will return true. <input type="submit" name="action" value="edit"> If the following is pressed, if ($action == 'new') will return true. <input type="submit" name="action" value="new"> See? Regarding what gets sent while pressing the enter key, not exactly sure on that, you can use javascript to help determine. Check out : http://ppewww.ph.gla.ac.uk/~flavell/www/formquestion.html And do some google searches for terms such as "enter, key, form, submit, javascript, html" and some others. And here's a thread that will help, some ideas within are better then others : [PHP] multiple submit buttons : ------------------------------------------------------------------- http://marc.theaimsgroup.com/?l=php-general&m=97513765915454&w=2 It's a very lengthy thread :-) regards, Philip Olson http://www.cornado.com/ On Tue, 27 Mar 2001, Augusto Cesar Castoldi wrote: > I had a form with just with one button, the action is a PHP file. And when > I hit "enter" the button (submit) form action was done. > > > Then I put other button (change) on this form, and now when I hit enter, > beside the > "pressed" button is the second one (I want that when I hit "enter" the > submit button is pressed), the PHP stops and the screen of the IE5 stays > blank. > > What I should do to solve this problem? > > thanks. > > Augusto > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#45758) next »