Learn HTML part 25

The Align and bgcolor attributes

To change a table position use the align attribute inside the table tag.
<table align="center">

Now we will try background color of orange for a table cell. For background color we will use bgcolor attribute.

For an example
<table border="2">
<tr>
<td bgcolor="orange"First </td>
<td> Second </td>
<td> Third </td>
</tr>
<tr>
<td> Fourth </td>
<td colspan="2"> Fifth </td>
</tr>
</table>

Result



Post a Comment

0 Comments