select specific column in all rows from table header class name

ajcall

New Member
In a table all \[code\]<th>\[/code\] are having \[code\]class\[/code\] and \[code\]<td>\[/code\] dont. Is it possible to apply the styles from those \[code\]<th>\[/code\] \[code\]class\[/code\] to all its corresponding \[code\]<td>\[/code\]'s with plain \[code\]css\[/code\] and dont need of any \[code\]script\[/code\]?Additionally \[code\]table\[/code\] is dynamic and so columns index may differ. So i cant use \[code\]nth-child\[/code\] and only way i can navigate it with \[code\]class\[/code\].Here is the FiddleAny better ideas for cross-browser?Update:table may have \[code\]n\[/code\] number of columns and not limited to \[code\]2\[/code\] columns
 
Back
Top