HTML Form with graphic button

O

Otto

Hello to all

I'm not a guru with html, but I don't understand why my
form do not work with a graphic button ?!

This work:
<input type='submit' name=mode value='Enregistrer'>

But not this:
<input type='image' src='images/co_avant.png' name=mode
value='Enregistrer'>

the "mode" will not be set with the value "Enregistrer".

Many thanks in advance for your help.


Otto
 
D

David Dorward

Otto said:
I'm not a guru with html, but I don't understand why my
form do not work with a graphic button ?!
This work:
<input type='submit' name=mode value='Enregistrer'>

But not this:
<input type='image' src='images/co_avant.png' name=mode
value='Enregistrer'>

Where is your alt attribute?
the "mode" will not be set with the value "Enregistrer".

No, images send the coordinates clicked (as fieldname.x and fieldname.y),
not the value.

This is described in the manual:
http://www.w3.org/TR/html4/interact/forms.html#input-control-types
 
T

Toby Inkster

Otto said:
This work:
<input type='submit' name=mode value='Enregistrer'>

But not this:
<input type='image' src='images/co_avant.png' name=mode
value='Enregistrer'>

the "mode" will not be set with the value "Enregistrer".

<input type="hidden" name="mode" value="Enregistrer">
<input type="image" src="images/co_avant.png" alt="Enregistrer"
name="Enregistrer" value="Enregistrer">
 
O

Otto

<input type="hidden" name="mode" value="Enregistrer">
<input type="image" src="images/co_avant.png" alt="Enregistrer"
name="Enregistrer" value="Enregistrer">
Many thanks for your help. It work!

Regards

Otto
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,430
Messages
2,571,676
Members
48,796
Latest member
Greg L.

Latest Threads

Top