I tried to follow this which is fine for background image replacement and fixed dimensions. But how about having an inline image as a image replacement where the image has a dynamic height?
<input type='checkbox' name='thing' value='valuable' id="thing"/><label for="thing"></label>
input[type=checkbox] {
display:none;
}
input[type=checkbox] + label {
background: #999;
height: 16px;
width: 16px;
display:inline-block;
padding: 0 0 0 0px;
}
input[type=checkbox]:checked + label {
background: #0080FF;
height: 16px;
width: 16px;
display:inline-block;
padding: 0 0 0 0px;
}
Looking for a replacement for
<label for="thing">
<input type='checkbox' name='thing' value='valuable' id="thing"/>
<img src="img.jpg" height="auto">
</label>