SunnyByfleet
Technical User
Following on from this thread: thread215-1262702
I basically wanted to have one image as a submit button and another as a cancel button.
That didn't work. for reasons explained in the other thread. I will try the solution suggested there, but am also puzzled.
To get around it not working, I resorted to having one image as a standard submit, and the other as a standard link.
It was something like this:
If I run that, and have process dump the contents of $_REQUEST using print_r, I see that there is no POST data as expected. Instead the form has a single GET consisting of tab=123 which comes from the second image.
If I move the second image outside the form it all works fine. However, that then presents separate formatting issues, and I would much rather it reside where it does.
Having seen the other thread I can now use the two image submit technique described, however I am curious to know why my images are behaving as they do, as it sounds odd.
Thanks
I basically wanted to have one image as a submit button and another as a cancel button.
That didn't work. for reasons explained in the other thread. I will try the solution suggested there, but am also puzzled.
To get around it not working, I resorted to having one image as a standard submit, and the other as a standard link.
It was something like this:
Code:
<form action="process.php" method="post">
....
<input type='image' src='m_submit.gif' />
<a href='main.php?tab=123'>
<img src='m_cancel.gif' border=0>
</a>
</form>
If I run that, and have process dump the contents of $_REQUEST using print_r, I see that there is no POST data as expected. Instead the form has a single GET consisting of tab=123 which comes from the second image.
If I move the second image outside the form it all works fine. However, that then presents separate formatting issues, and I would much rather it reside where it does.
Having seen the other thread I can now use the two image submit technique described, however I am curious to know why my images are behaving as they do, as it sounds odd.
Thanks