Re: Easy HTML PHP question

From: Date: Thu, 29 Mar 2001 00:10:42 +0000
Subject: Re: Easy HTML PHP question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-45974@lists.php.net to get a copy of this message
For images i think its different, i don't think you can force the image name that value instead the value gets turned into "button_x" and "button_y" with relation to where the mouse clicked on the image. In any event try using GET method instead of POST method to see whats displayed on the url string then you will have your answer ----- Original Message ----- From: "Paulson, Joseph V. "Jay"" <jay.paulson@viatel.com> To: <php-general@lists.php.net> Sent: Wednesday, March 28, 2001 3:51 PM Subject: [PHP] Easy HTML PHP question > Hello everyone- > I have a pretty easy question that I can't seem to answer myself so I'm > coming to you all. Below you'll see some html code for a form. Now what > happens is that when I click on one of the images to submit the form (either > on the update_event.gif image or the delete_event.gif image) the form goes > to redirect.php. The problem I am having is that I have a switch statement > which runs off the variable "button" on the redirect.php page (hence the > name="button" in the form). However, you would think if you clicked on the > update_event.gif that "button" would be set to "updateEvent" on the > redirect.php page. Well it isn't set to anything at all! Here's the other > problem, since I have two different acctions I can do on the same page I > can't do Hidden variables on this page because I can't have button being two > different values. > > Anyway, what I need is when a user clicks on the image to submit the form I > need the button to be set to the correct value. Any suggestions on how to > do this?? > > <form action="redirect.php" method="post"> > > <input type="image" border="0" name="button" > src="images/update_event.gif" > value="updateEvent"> > > <input type="image" border="0" name="button" > src="images/delete_event.gif" > value="deleteEvent"> > > </form> > > Thanks! > Jay Paulson > Developer, Web Technologies > Viatel, Inc. > http://www.viatel.com > > -- > 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 (#45974) next »