isset post with form - solved

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
mickd
Forum Contributor
Posts: 397
Joined: Tue Jun 21, 2005 9:05 am
Location: Australia

isset post with form - solved

Post by mickd »

i dont know why but is it just me or does isset($_POST['1_1']) does not work if the form used input type="image" name="1_1"?
Last edited by mickd on Thu Aug 04, 2005 2:04 am, edited 1 time in total.
User avatar
Skittlewidth
Forum Contributor
Posts: 389
Joined: Wed Nov 06, 2002 9:18 am
Location: Kent, UK

Post by Skittlewidth »

Had a quick look into this and apparantly if you check for $_POST['1_1_x'] and $_POST['1_1_y'] you should get something.
When the graphical submit button is clicked, the coordinates of the click are sent with the form submission as name.x=x-value and name.y=y-value where name is the value of the NAME attribute, x-value is the click's pixels from the left of the image, and y-value is the click's pixels from the top of the image.
In PHP the ".x" and ".y" converts to an underscore.
I haven't got it to work myself yet but to save me typing here is a post that explains things for you :)


http://www.webmasterworld.com/forum21/9694.htm
mickd
Forum Contributor
Posts: 397
Joined: Tue Jun 21, 2005 9:05 am
Location: Australia

Post by mickd »

thanks, got it to work now. dont know why they made the input img like that for :?
Post Reply