How is equivalent align and colspan table's tag in .css style file? For example
<table colspan="2" align="center">
How is equivalent align and colspan table's tag in .css style file? For example
<table colspan="2" align="center">
Let me elaborate a bit.
colspan defines the number of columns a cell should span in a group of columns.
Example :DEMO FIDDLE
<table border="1">
<tr>
<td>Cell A</td>
<td>Cell B</td>
<td>Cell C</td>
</tr>
<tr>
<td colspan="3">Cell ABC</td>
</tr>
</td>
</table>
In this example i have specified colspan="3" for the second row <td>
. Hence this <td>
will span 3 columns of the table.
align is a style attribute which has 3 options left, right, centre. This will determine where you want to place the table on your page.
Example:
<table align="center">
<tr>
<td>Cell A</td>
<td>Cell B</td>
<td>Cell C</td>
</tr>
</table>