修改checkbox的样式

<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>chec</title>

<style>
*{margin:0px;padding: 0px;}
span.wrappicinput {position: relative;}
.wrappicinput .input_check {position: absolute;width: 12px;height: 12px;visibility: hidden;}
.wrappicinput .labelcheck {position: absolute;width: 12px;height: 12px;}
.wrappicinput .input_check+label {display: inline-block;width: 12px;height: 12px;background: url(./easyui/themes/default/images/tree_icons.png) no-repeat;background-position: -210px -21px;}
.wrappicinput .input_check:checked+label {background-position: -226px -21px;}

</style>
</head>
<body>

 

<span class="wrappicinput">
<input type="checkbox" class="input_check" id="check1">
<label class="labelcheck" for="check1" ></label>
</span>


</body>
</html>

 

posted on 2017-11-01 10:57  luziluck  阅读(216)  评论(0编辑  收藏  举报

导航