The following works very well to highlight a table cell with a background color when the cell is clicked:
Code: jQuery("td").toggle( function () { jQuery(this).addClass("highlight"); }, function () { jQuery(this).removeClass("highlight");}); This also works with toggleClass: Code: jQuery("td").click(function() { jQuery(this).toggleClass ('highlight');}); css is simple: highlight {background:yellow;} I just can't figure out how to incorporate a fadeIn and fadeOut effect with toggle or toggleClass. I'd like to be able to control the speed of the highlight when a user clicks a cell on the table. Thanks in advance for any ideas!