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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

<td width="1" bgcolor="#8FA2B5"></td> is actuall

Status
Not open for further replies.

EchoAlertcom

IS-IT--Management
Oct 8, 2002
239
US
Hello,

I am using
Code:
<td width=&quot;1&quot; bgcolor=&quot;#8FA2B5&quot;></td>
to create a verticle line that is dynamically the right size based off of how much content is in the next column. The issue is I only want it 1 pixel wide. But when the page renders it is 2-3 pixels wide. I have two questions:

1.) How do I fix this still using the bgcolor as the vertical bar?
2.) Is there a way to use a 1-pixel gif that will resize automatically to the height of the column?

Sincerely.
Steve
 
Hi Steve,

I don't understand exactly what you mean with a verticle line that is dynamically the right size based off of how much content is in the next column so maybe you better post the code of the whole table, including styles etc.

But as far as I understand, you want a 1 pixel vertical line at the left of the content column? Maybe this example is what you want? If not, explain us what realy want.

I added optional the padding-left to the style. You can vary the width of it from 0 to 'what you want' or just leave it (= 0)

<html>
<head>
<style>
.tableshadowborder {
border-left: 1px solid #8FA2B5;
background-color: #F5F8FC;
padding-left:2px;
}
</style>
</head>
<body>

<table width=550 cellpadding=0 cellspacing=0>
<tr>
<td width=&quot;75&quot;>column 1</td>
<td width=&quot;75&quot;>column 2</td>
<td width=&quot;75&quot;>column 3</td>
<td class=&quot;tableshadowborder&quot; width=&quot;250&quot;>cell content in content column</td>
<td width=&quot;75&quot;>column 5</td>
</tr>
<tr>
<td>column 1</td>
<td>column 2</td>
<td>column 3</td>
<td class=&quot;tableshadowborder&quot;>cell content in content column</td>
<td>column 5</td>
</tr>
<tr>
<td>column 1</td>
<td>column 2</td>
<td>column 3</td>
<td class=&quot;tableshadowborder&quot;>cell content in content column</td>
<td>column 5</td>
</tr>
<tr>
<td>column 1</td>
<td>column 2</td>
<td>column 3</td>
<td class=&quot;tableshadowborder&quot;>cell content in content column</td>
<td>column 5</td>
</tr>
<tr>
<td>column 1</td>
<td>column 2</td>
<td>column 3</td>
<td class=&quot;tableshadowborder&quot;>cell content in content column</td>
<td>column 5</td>
</tr>
</table>
</body>
</html>

Hope this helps,
Erik <-- My sport: Boomerang throwing !!
!! Many Happy Returns !! -->
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top