image as a button

liunx

Guest
I have a button form element and I want to paint it as an image:<br />
<br />
<input type="button" name="search" value="search" class="btn" onClick="actionListener()"><br />
<br />
<br />
I want to display image instead of an html button, changing code to:<br />
<br />
<input type="image" src=http://www.webdeveloper.com/forum/archive/index.php/"images/search.gif" name="search" value="search" onClick="actionListener()"><br />
<br />
does not work. How can I make image behave as button?<br />
<br />
thanks,<br />
webtekie<!--content-->www.vladdy.net/Demos/SubmitStyling.html<!--content-->Ok, but in this example type is submit. I have other actions that act as submit. Or does this mean that I can have <input type="submit" name="search"> that submits the page but reacts to getElementById("search") as I used to have?<!--content-->Type does not matter, you give an element an id or class and style to your desire.<!--content-->
 
Back
Top