Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

using image as reset button

i want to use an image as reset button what code i should use in HTML and CSS ?

like image 544
Muhammad Hussain Avatar asked Sep 14 '26 16:09

Muhammad Hussain


2 Answers

Think this should do the trick.

 <button type="reset">
    <img src="#" alt="" />
 </button>
like image 73
Hux Avatar answered Sep 16 '26 05:09

Hux


Good question. Can't be done AFAIK. Images can only serve as submit buttons. You would have to use Javascript to do a onclick="this.form.reset()" on a normal image, or style a normal reset button using a background image (should be possible without problems).

like image 38
Pekka Avatar answered Sep 16 '26 05:09

Pekka