We Recommend

Pro JavaScript Techniques Pro JavaScript Techniques
Pro JavaScript Techniques is the ultimate JavaScript book for the modern web developer. It provides everything you need to know about modern JavaScript, and shows what JavaScript can do for your web sites. This book doesn't waste any time looking at things you already know, like basic syntax and structures.


Posted By

hellolabs on 09/19/07


Tagged

zebratable


Versions (?)


Who likes this?

11 people have marked this snippet as a favorite

francisre
neuroasis
cwoodley
vali29
AgentPhoenix
yetanother
orhanveli
martingoldszein
snucko
blackabee
korzhik


JQuery: dynamic table zebrastripes


Published in: JavaScript 


  1. // dynamic table zebrastripes
  2.  
  3. $(document).ready(function(){
  4.  
  5. $('.zebra tr:even').addClass('alt');
  6.  
  7. $('tr').mouseover(function(){
  8. // $('tr:not(\'.footerrow\')').mouseover(function(){
  9. $(this).addClass('over');})
  10. .mouseout(function() {
  11. $(this).removeClass('over');});
  12.  
  13. });

Report this snippet 

You need to login to post a comment.