im trying to color the 开发者_JAVA百科<a>
background color
<div id="contact"><a href="mailto:name@.domain.net>name</a>
with the selector
$('#contact a').css("background", "red");
however im not successfull, where is my error?
you are missing a double quotes in the end of href
see demo http://jsfiddle.net/URJPV/1/
try this one:
<a id="contact_link" href="mailto:name@.domain.net>name</a>
$('a#contact_link').css("background", "red");
精彩评论