1 <script src="../common/jquery-1.6.2.min.js"></script> 
2 <script>
3 $(document).ready(function() {
4 $('tr').addClass('odd');
5 $('tr:even').addClass('even'); //奇偶变色,添加样式
6 });
7 </script>
8 <style>
9 #hacker tr:hover{
10 background-color:#09C; //使用CSS伪类达到鼠标移入行变色的效果,比Jquery 的mouseover,hover 好用
11 }
12
13 .odd {
14 background-color: #ffc; /* pale yellow for odd rows */
15 }
16 .even {
17 background-color: #cef; /* pale blue for even rows */
18 }
19 </style>

  

编辑器加载中...

相关文章:

  • 2022-02-07
  • 2022-12-23
  • 2022-12-23
  • 2021-12-10
  • 2021-10-21
  • 2022-12-23
  • 2022-12-23
  • 2021-11-30
猜你喜欢
  • 2021-08-07
  • 2021-06-18
  • 2022-12-23
  • 2021-07-29
  • 2022-12-23
  • 2021-07-08
  • 2022-12-23
相关资源
相似解决方案