Created
September 6, 2011 23:06
-
-
Save fearofcode/1199253 to your computer and use it in GitHub Desktop.
dicking around with jquery UI
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<h2 class="demoHeaders">Radio buttons with icons</h2> | |
<div id="radioWithIcons"> | |
<input type="radio" id="radio1" name="radio" /><label for="radio1"><img src="http://www.google.com/favicon.ico"/> Choice 1</label> | |
<input type="radio" id="radio2" name="radio" checked="checked" /><label for="radio2"><img src="http://www.yahoo.com/favicon.ico"/> Choice 2</label> | |
<input type="radio" id="radio3" name="radio" /><label for="radio3"><img src="http://www.fogcreek.com/favicon.ico"/> Choice 3</label> | |
</div> | |
<script type="text/javascript"> | |
$(function(){ | |
$("#radioWithIcons a").click(function(ev) { ev.preventDefault(); }); | |
$("#radioWithIcons").buttonset(); | |
$("#radioWithIcons").hover(function() { console.log("in") }, | |
function() { console.log("out") } ) | |
}); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment