Thanks. :) Yeah, selectors are a kind of hobby for me. Sad, I know.
Anyway, I'm thinking we can make it even more terse this way:
$('tr[td:contains("term")]').addClass('foo');
Cheers,
Karl
On Feb 8, 2007, at 2:38 PM, James Thomas wrote:
Wow, that is terse! I like it. I really need to get better at
selectors as
that wouldn't have occurred to me. Nice.
James
Karl Swedberg-2 wrote:
Hi Graeme,
Try something like this:
$('td:contains("term")').parent().addClass('foo');
--Karl
_________________
Karl Swedberg
www.englishrules.com
www.learningjquery.com
On Feb 8, 2007, at 1:16 PM, Graeme B. Davis wrote:
Hello,
I'm looking to highlight 1 or more rows of a table which have a
cell whose contents match a search term I provide. Does anyone
have an easy way to do this?
Thanks!
Graeme
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
--
View this message in context: http://www.nabble.com/Search-term-
table-row-highlighting-best-practice-tf3194998.html#a8872600
Sent from the JQuery mailing list archive at Nabble.com.
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/