HTML CSS examples for CSS Widget:Table Cell
Style table with alternate th and td
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> table<!-- w w w . j a v a2 s . com--> { width:201px; border:2px solid Chartreuse; text-align:left; } th { background:yellow; } td { background:green; } </style> </head> <body> <table cellspacing="0;"> <tbody> <tr> <th colspan="6">Lo</th> </tr> <tr> <td colspan="6">Lo</td> </tr> <tr> <th>Lo</th> <td>Lo</td> <th>Lo</th> <td>Lo</td> <th>Lo</th> <td>Lo</td> </tr> </tbody> </table> </body> </html>