dcsimg
Login | Register   
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX

By submitting your information, you agree that devx.com may send you DevX offers via email, phone and text message, as well as email offers about other products and services that DevX believes may be of interest to you. DevX will process your information in accordance with the Quinstreet Privacy Policy.


Tip of the Day
Language: Web
Expertise: All
Feb 22, 1999

WEBINAR:

On-Demand

Application Security Testing: An Integral Part of DevOps


Put Non-Breaking Spaces in Empty HTML Table Cells

The tables that you design so carefully could end up looking odd in Internet Explorer or Netscape Navigator. The trouble is that browsers treat empty table cells differently. For instance, an empty cell may be rendered without borders, which can be visually distracting. To give an even appearance to all cells, including empty cells, insert the HTML code for a non-breaking space ( ). A regular blank space doesn't work. You can see the effect of using   by viewing this code in your browser:
 
<HTML>
<HEAD>
<TITLE>Empty cells</TITLE>
</HEAD>
<BODY>

<P>
<TABLE bgColor=#99cccc 
border=1 borderColor=#669999 
borderColorDark=#ffffff borderColorLight=#000000 
cellPadding=4 cellSpacing=1>
    
    <TR>
        <TD>A</TD>
        <TD> </TD>
        <TD>2</TD></TR>
    <TR>
        <TD>B</TD>
        <TD>2</TD>
        <TD>5</TD></TR>
    <TR>
        <TD>C</TD>
        <TD>6</TD>
        <TD>&nbsp;</TD></TR>
        
</TABLE></P>

</BODY>
</HTML>
Browsing this code looks like:

A 2
B 2 5
C 6  

Ken Cox
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap
×
We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.
Thanks for your registration, follow us on our social networks to keep up-to-date