使用jQuery改变HTML元素的CSS样式

<script>
$(document).ready(function() {
$("#target1").css("color","red");
});
</script>

<!-- Only change code above this line. -->

<div>
<h3>jQuery Playground</h3>
<div>
<div>
<h4>#left-well</h4>
<div>
<button>#target1</button>
<button>#target2</button>
<button>#target3</button>
</div>
</div>
<div>
<h4>#right-well</h4>
<div>
<button>#target4</button>
<button>#target5</button>
<button>#target6</button>
</div>
</div>
</div>
</div>

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/zgfddp.html