How can I make my <input type=“submit” /> an image?

前端 未结 6 1765
不知归路
不知归路 2021-02-02 11:07

I have a beautiful little CSS image that needs to be a button. I\'ve tried about 20 different methods, none of which work. I just either get a blank nothing or a border with no

6条回答
  •  南旧
    南旧 (楼主)
    2021-02-02 11:38

    input[type=submit] {
        background: url(http://lrroberts0122.github.com/DWS/lab6/level-2/images/button.png);
        border: 0;
        display: block;
        height: _the_image_height;
        width: _the_image_width;
    }
    

提交回复
热议问题