<html>
<head></head>
<body>
<ul>
<li id="test" style="background-color:red;">aaaaaaaaaaa</li><li>bbbbbbbbbb</li><li>cccccccccccc</li><li>dddddddddd</li>
</ul>
<script type="text/javascript">
document.getElementById("test").onclick=function(){
this.style.backgroundColor="blue";
this.style.color="blue";
}
</script>
</body>
</htmL>
<head></head>
<body>
<ul>
<li id="test" style="background-color:red;">aaaaaaaaaaa</li><li>bbbbbbbbbb</li><li>cccccccccccc</li><li>dddddddddd</li>
</ul>
<script type="text/javascript">
document.getElementById("test").onclick=function(){
this.style.backgroundColor="blue";
this.style.color="blue";
}
</script>
</body>
</htmL>
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货