Simple HTML code - Netscape

windows

Guest
I though the following was a very simple code.<br />
<br />
<table width="420" border="0" cellspacing="0" cellpadding="0"><br />
<tr> <br />
<td bgcolor="#666666" width="40"></td><br />
<td height="3" width="340"></td><br />
<td bgcolor="#666666" width="40"></td><br />
</tr><br />
</table><br />
<br />
It doesn't give me the desired results on Netscape 4.7. Also, is there any site where I can check for browser compatibility issues online either by pasting the code or providing the URL?<br />
<br />
Thanks.<!--content-->Netscape will not render a table that is empty. add &nbsp; to the cells.<br />
<br />
<table width="420" border="0" cellspacing="0" cellpadding="0"><br />
<tr> <br />
<td bgcolor="#666666" width="40">&nbsp;</td><br />
<td height="3" width="340">&nbsp;</td><br />
<td bgcolor="#666666" width="40">&nbsp;</td><br />
</tr><br />
</table><!--content-->Scoutt is on to something with his answer.<br />
<br />
Additionally, you can test your code for typos, nesting errors, browser specific tags and attributes, unquoted attributes, and so on, by running it through <!-- m --><a class="postlink" href="http://validator.w3.org/detailed.html">http://validator.w3.org/detailed.html</a><!-- m --><!--content-->Giz, marry yourself with the validator and move to Africa.<br />
<br />
Since there's no content inside the table, its height is 0 pixels which is the same as nothing. Adding &nbsp; gives it the height of the default font used. A fixed height may be given by e.g. style="height:100px".<!--content-->You know, I sometimes wonder if marrying the validator wouldn't be a bad idea. Sure, it complains if you aren't perfect, but at least it gives you a clue as to what your problem is and then will accept you back no matter how many times you don't get it right. I find it substantially easier to understand than women and it doesn't mind if I don't visit for months at a time.<br />
<br />
As for Manish's question, I have never seen a site that gives you browser specific compatability problems based on your code. The best you can do is use the W3C validator (<!-- m --><a class="postlink" href="http://validator.w3c.org">http://validator.w3c.org</a><!-- m -->) like giz suggested, or use a compatibility chart. I don't know where any are off hand, but I'm sure a Google search would turn up a couple thousand.<br />
<br />
Oh, the website AnyBrowser.com (<!-- m --><a class="postlink" href="http://www.anybrowser.com">http://www.anybrowser.com</a><!-- m -->) is also pretty useful. You can see what your page would look like through other browsers.<!--content-->
 
Back
Top