Hi Brandon,
the + combinator is for the next sibling element. since td is never a
sibling of tr, your selector isn't going to work there.
To get the first td in each tr, use the :first-child pseudo-class
:
jQuery('#rank-products table.product-table td:first-child').addClass
('rank-handle');
Hope that helps
--Karl
_________________
Karl Swedberg
www.englishrules.com
www.learningjquery.com
On Aug 24, 2007, at 8:29 PM, Benjamin Sterling wrote:
Can we see the table you are working with? Also, try putting tbody
tr td:first..
On 8/24/07, Brandon < [EMAIL PROTECTED]> wrote:
I am trying to target the first table cell in each table row. I'm not
familiar with the + character, but I thought it might be the key, but
it wasn't:
jQuery('#rank-products table.product-table tr + td').addClass('rank-
handle');
And of course this doesn't work either.
jQuery('#rank-products table.product-table tr td:first-
child').addClass('rank-handle');
Also, it's important that this doesn't target nested tables (eg.
#rank-
products table.product-table table).
Is this possible without getting too complex?
--
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com