NorCalKnockOut
NorCalKnockOut

Reputation: 878

Combining two CSS elements

How would I combined the follow into one block

#idOne td, th {
  ......
}

#idTwo td, th {
  ......
}

I tried

#idOne td, th,
#idTwo td, th {
  .....
}

but theth is included as its own.

Any ideas? Thanks

Upvotes: 0

Views: 80

Answers (2)

verism
verism

Reputation: 1164

Given the question example, the correct way would be this:

#idOne td, #idTwo td, th {
  .....
}

But I've a feeling that the example might not be quite as you intend.

Upvotes: 1

David Millar
David Millar

Reputation: 1878

You need to specify the parent for each of the td and th tags:

#idOne td, #idOne  th, #idTwo td, #idTwo th {
  ......
}

Upvotes: 3

Related Questions