Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

bad formatting table cell

Status
Not open for further replies.

ryanbrand

Programmer
Oct 28, 2003
22
US
One of my table cells isn't letting the width be fully used up. It acts as if there's a 2 inch margin on the right side of one of the cells.

Could you help me fix this? The code is below.

Thank you!!

Ryan

------------------------------------------

<html>
<head>
<style type="text/css">
.border
{
border-style: ridge;
border-left-width: 3px;
border-right-width: 3px;
border-top-width: 3px;
border-bottom-width: 3px
}
</style>
</HEAD>
<body>
<TABLE BORDER="0" WIDTH="780" CELLSPACING="0" CELLPADDING="0">
<TR>
<TD class="border" WIDTH="118" valign="top" align="left" bgcolor="#663399">
<ul id="sectionNav">
<li>link</li>
<li>link</li>
<li>link></li>
<li>link</li>

</ul>
</TD>
<TD class="border" WIDTH="25" border="1" valign="top">a</TD>
<!-- Content begins here -->

<TD WIDTH="455" class="border" VALIGN="top" align="right"><BR>
Why doesn't this go to the far right of the table cell, but stops about 2 inches befoer
</TD>

</TR>
</TABLE>
</body>
</html>
 
That's because the table cell widths add up to only:
118 + 25 + 455 = 598
while the table has been set to be 780 in width. If you want to keep your layout as it is try setting each of the cell widths as:
118, 25 and (780-143=)637 respectively.

Pete.


Web Developer &amp; Aptrix / Lotus Workplace Web Content Management (LWWCM) Specialist
w: e: Pete.Raleigh(at)lclimited.co.uk
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top