Horje

How to set Default CSS Settings for HTML <caption> Tag

Follow the Example.

index.html
Example: HTML
<style>
table,th,td { border:1px solid black;
}
caption { display: table-caption; text-align: center;
}
</style>
<table> <caption>Monthly savings</caption> <tr> <th>Month</th> <th>Savings</th> </tr> <tr> <td>January</td> <td>$100</td> </tr> <tr> <td>February</td> <td>$50</td> </tr>
</table>

Output should be:

How to set Default CSS Settings for HTML <caption> Tag




Type :
html
Category :
Web Tutorial
Sub Category :
HTML Tag
Uploaded by :
Admin