Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HTML: how to make 2 tables with different CSS [closed]

I want to put two tables (on the same page) which should render differently (i.e. use different CSS for each table). Is it possible?

like image 406
michelemarcon Avatar asked Nov 03 '11 08:11

michelemarcon


People also ask

How do I make two tables with different CSS?

You need to assign different classes to each table. and use them in your html code. Show activity on this post. Of course, just assign seperate css classes to both tables.


1 Answers

In your html

<table class="table1"> <tr> <td> ... </table>  <table class="table2">  <tr> <td> ... </table> 

In your css:

table.table1 {...} table.table1 tr {...} table.table1 td {...}  table.table2 {...} table.table2 tr {...} table.table2 td {...} 
like image 103
Jon Egerton Avatar answered Sep 28 '22 06:09

Jon Egerton