Showing posts with label html tables. Show all posts
Showing posts with label html tables. Show all posts

BG Color of Table Cell


To change your background color of Table Cell in your html file you can use the codes are given below.Open your notepad program and write the codes.

<html>
<body>

<table style="background-color:#FFFFE0;">
<tr style="background-color:#BDB76B;color:#ffffff;">
<th>Table Header</th><th>Table Header</th>
</tr>
<tr>
<td>Table cell 1</td><td>Table cell 2</td>
</tr>
<tr>
<td>Table cell 3</td><td style="background-color:#ff0000;">Table cell 4</td>
</tr>
</table>



</body


















>
<

/html>

Open the html file and see the result.
See BG Color of Table

R












































































ow
Se


e



















BG Color of whole Table





BG Color of Table Row

Using this html codes any one can change the table row color. Codes are given below.
1. Open Notepad.
2. write the codes like below.


<html>
<body>

<table style="background-color:#FFFFE0;">
<tr style="background-color:#BDB76B;color:#ffffff;">
<th>Table Header</th><th>Table Header</th>
</tr>
<tr>
<td>Table cell 1</td><td>Table cell 2</td>
</tr>
<tr>
<td>Table cell 3</td><td>Table cell 4</td>
</tr>
</table>


</body>
</html>

3. Now save this as test_heading.html
4. Open the file in any browser and see the output.






See   BG Color of whole Table


BG Color of whole Table by PHP, MySQL, CSS, HTML and SEO Tutorials

By using this html codes you can set any color in the table background. Write the html codes in your notepad and save it as bg_tablecolor.html



<html>
<body>

<table style="background-color:#6dc066;">
<tr>
<th>Table Header</th><th>Table Header</th>
</tr>
<tr>
<td>Table cell 1</td><td>Table cell 2</td>
</tr>
<tr>
<td>Table cell 3</td><td>Table cell 4</td>
</tr>
</table>

</body>
</html>

Open this file in any of your browser. And see this is like as image given below.
See BG Color of table row