Jump to content

using image as an input submit doesn't work in IE


webguync

Recommended Posts

I think this is an IE issue. I have a submit button for a form and when I use an image as the submit button it doesn't work in IE. Works fine in FF though. When I take out the image part and just use the default submit, works fine in IE.

Here is the code with the image

 

echo '<input name="Update" type="image" value="submit" id="Update" src="images/Update.png" />

 

 

 

Link to comment
Share on other sites

you could try:

echo '<button name="Update" type="submit" id="Update"><img src="images/Update.png" /></button>';

 

 

then add this to the CSS to stop it looking like an ordinary submit button:

button {
  border: 0;
  background: none;
}

 


 

alternatively, you could use a button with no value, and add an image background to it using CSS.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.