<button> versus <input type=“image”>

前端 未结 3 863
耶瑟儿~
耶瑟儿~ 2021-01-04 10:18

This is for an \"Add to basket\" control for which one of my colleagues has designed a nice graphic. Obviously it should generate a post request, which a simple hyperlink i

3条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-04 11:03

    Input type="Image" supports the Disabled attribute and the browser will Grey out the image for you. With Type=Button you'd have to provide an alternate grey image.

提交回复
热议问题