HTML Table Background Color and Border Color

1 Open Notepad

2  Copy code and Paste

3  <!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<body>
<table border="10" bordercolor="orange" bgcolor="cyan">
<caption align=top>Student Detail</caption>
<tr>
<th>Student Name</th>
<th>Roll Number</th>
<th>Class</th>
</tr>
<tr>
<td>vinod </td>
<td>01</td>
<td>BSC</td>
</tr>
<tr>
<td>Mohit </td>
<td>02</td>
<td>BSC</td>
</tr>
</table>
</body>
</html>

4  Save as . 
5  Output: 
  
Student Detail
Student Name Roll Number Class
vinod 01 BSC
Mohit 02 BSC



Share this

Related Posts

Previous
Next Post »