Posted by Tyrone Slothrop on 10/22/05 18:08
On Sat, 22 Oct 2005 08:27:26 +0200, Otto <ohaldi@freesurf.ch> wrote:
>Hello
>
>I have a PHP script where I changed the buttons to graphic
>buttons.
>
>Before:
>?>
><input type='submit' name=mode value='Suivant'>
><input type='submit' name=mode value='Enregistrer'>
>
>After:
>?>
><input type="image" src="images/co_next.png"
>alt="Affiche le nom suivant!"
>name=mode value="Suivant">
>
><input type="image" src="images/co_save.png"
>alt="Enregistrer les modifications!"
>name=mode value="Enregistrer">
>
>etc.
><?php
>
>Unfortunately the mode variable do no change any more.
>Could somebody help me or tell me why when I'm using
>type='submit' that works and not any more with
>type='image' ?
>
>Or how can I resolve this problem?
>
>Many thanks in advance for your help.
>
>Regards
>
>Otto
Otto:
Look at this:
http://wiki.opensymphony.com/display/WW1/Multiple+Graphical+Submit+Buttons?focusedCommentId=3345
I believe you are getting "x" and "y" values being passed as well.
You may have to evaluate the mode key differently:
<?
foreach ($_POST as $k=>$v) {
if (strstr ($k, "mode") { $mode = $v; }
}
Navigation:
[Reply to this message]
|