HTML代码:
<aid="theLink"></a>
CSS代码:
#theLink{
display:block;/*由于标签a是内链元素,以是使用这句话将内链元素转化成块状元素,前面的width和height才起感化*/
width:120px;
height:41px;
margin:0auto;
background:url(../images/normal.gif)no-repeat;
}
#theLink:hover{background:url(../images/press.gif)no-repeat;}
HTML代码:
<aid="buttonBlock"></a>
CSS代码:
#theLink{
display:block;
width:120px;
height:41px;
margin:0auto;
background:url(../images/buttonBG.gif)no-repeat;
}
#theLink:hover{background:url(../images/buttonBG.gif)no-repeat0-41px;}
欢迎光临 仓酷云 (http://www.ckuyun.com/) | Powered by Discuz! X3.2 |