纯CSS复选框图像替换
我在表中有一个复选框列表。(该行中的多个CB之一) <tr><td><input type="checkbox" class="custom_image" value="1" id="CB1" /><label for='CB1'>&nbsp;</label></td></tr> <tr><td><input type="checkbox" class="custom_image" value="2" id="CB2" /><label for='CB2'>&nbsp;</label></td></tr> <tr><td><input type="checkbox" class="custom_image" value="3" id="CB3" /><label for='CB3'>&nbsp;</label></td></tr> <tr><td><input type="checkbox" class="custom_image" value="4" id="CB4" /><label for='CB4'>&nbsp;</label></td></tr> 我想用一对自定义的开/关图像替换复选框图像,我想知道是否有人对如何使用CSS更好地了解? 我已经找到了这个“ CSS ninja”教程,但是我不得不承认发现它对我来说有点复杂。 http://www.thecssninja.com/css/custom-inputs-using-css 据我所知,您可以使用伪类 td:not(#foo) > input[type=checkbox] + label { background: url('/images/off.png') 0 0px no-repeat; height: 16px; padding: 0 …