Background images and colors in tables under Netscape
Sponsored Links
Here is what you want to do... you make a table with a background image and put background color in some of the table cells. All this looks good in Internet Explorer, but the moment you check it in Netscape, you get a rude shock. Netscape blatantly ignores the bgcolor attribute of <td>, overriding it with the background (image) of <table>.
You check and recheck the HTML code but nothing seems to be wrong with it.
Here is how the table would look... (the table has a picture of Freddie Mercury as its background). Note: Internet Explorer users might not know the difference since the two tables below are rendered in the same manner. Hence, it is recommended that you view this page in Netscape.
| CELL 1 |
| CELL 2 |
| CELL 3 |
| CELL 4 |
| CELL 5 |
Here is a simple solution to your problem.
Put a background attribute in each <td> where a background color is desired and supply it with a URL of a 1X1 pixel transparent .gif image. The code for <td> which works both in Netscape and I.E. is:
<td bgcolor="#color_you_desire" background="blank.gif"> Cell Contents</td>
The bgcolor attribute can take either hexadecimal color code or color name. Download the blank.gif from here.
Corrected table display in Netscape.
| CELL 1 |
| CELL 2 |
| CELL 3 |
| CELL 4 |
| CELL 5 |
Further, to prevent tiling of the background image, place this table inside an outer 1 cell table. (Refer the previous tip for further details)
|
Page contents: HTML Tip: Getting Netscape to display correctly a table cell background or color on a web page.
Comments, questions, feedback... whatever!
Recent Articles
Recent Blog Posts
Popular Articles
- Hotmail Sign In page
- Create a Hotmail account - Instructions
- Create Gmail address
- Download and install Outlook Express
- Get your free Gmail address
- Outlook Express new version
- Create my own email address
- Browers for Windows list
- Get email address
- Color combinations for web sites and pages
- Create Yahoo ID
More web tips & tricks
- Outlook Express Help - tips & tricks (53)
- Windows Live Mail help and tips (36)
- Windows Mail help (25)
- Hotmail help and tips (42)
- Yahoo help & support (45)
- AOL email help (26)
- Gmail help and tips (36)
- Internet tips & tricks (12)
- Web Design tips & tricks (33)
- HTML, Javascript tips tricks (68)
- Web Promotion tips & tricks (8)
- Graphics tips & tricks (20)
