0

How to make my table to center??

please help guru

22nd Dec 2016, 3:14 AM
GVecomYT
GVecomYT - avatar
4 odpowiedzi
+ 3
It's preferrable to use css to the parent instead of depreciated tag property. You could do it inline ( better way to separate ): <div style="text-align:center;"><table></table></div> Another way to horizontally center an element like a table, you can set its css margin property to "auto" ( left and right are suffisant ): <table style="margin:auto;">
22nd Dec 2016, 6:19 AM
visph
visph - avatar
+ 2
<table align="center"> <tr> <th>Month</th> <th>Savings</th> </tr> <tr> <td>January</td> <td>$100</td> </tr> <tr> <td>February</td> <td>$80</td> </tr> </table>
22nd Dec 2016, 3:38 AM
Adnen Rebai
Adnen Rebai - avatar
+ 1
thanks :D
22nd Dec 2016, 5:18 AM
GVecomYT
GVecomYT - avatar
0
you can use align or position property to place the table center
22nd Dec 2016, 3:33 AM
Jishnu Jayarajan