Re: submit form problem

From: Date: Sun, 12 Aug 2001 22:01:11 +0000
Subject: Re: submit form problem
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-62348@lists.php.net to get a copy of this message
> I've a script accepting four different forms depending on the user choice. > Some of the forms have two submit buttons forcking actions accordingly to > the pressed button. > > The problem is: $HTTP_POST_VARS["submit"] is not set if the user press ENTER > instead of clicking the button and the scripts cannot return a response for > it is not clear which button has been pressed. > > Hidden field cannot works with two submit buttons for I'll have two values, > but again cannot cach the user choice in case of ENTER press. Either explicitly state a "default" action, or analyze the actual data coming in to decide what the user must have meant. I *thought* enter was only supposed to work in a text field when there's only one SUBMIT... But it wouldn't shock me if some browser broke that. -- WARNING richard@zend.com address is an endangered species -- Use ceo@l-i-e.com Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm Volunteer a little time: http://chatmusic.com/volunteer.htm

« previous php.general (#62348) next »