Previous Message
Next Message

Specifying a td tag without a name

Sent by jack fredricks on 2 May 2005 20:08


you can use adjacent-selectors

http://www.w3.org/TR/CSS21/selector.html#adjacent-selectors

td {background:#ccc;} /* all tds */
td + td {background:#f00;} /* first td in a row */
td + td + td {background:#0f0;} /* 2nd td in a row */
td + td + td + td {background:#00f;} /* 3rd (and any after) td in a row */
	
however, you'll might run into some logic issues, depending on your
needs. You should be able to get round this if the table has a class.
Still, doing that on 600 pages will be easier.

ie

table.myclass td + td + td + td {background:pink;} 

however..sob sob...this wont work in IE.
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread:

Possibly related: