Line between two paragraphs

liunx

Guest
In IE and Netscape the following code gives me my paragraph, space, gif colored divider, space paragraph. In Opera all I get is a dot between the two paragraphs. What did I miss?<br />
<br />
<table border="0" cellspacing="0" cellpadding="5" width="100%" align="left" valign="top"><br />
<tr><br />
<td width="50%" align="left" valign="top"><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p><br />
</td><br />
<td width="2" align="center" valign="top" height="100%"><img src=http://www.htmlforums.com/archive/index.php/"images/center.gif" width="2" height="100%"><br />
</td><br />
<td width="50%" align="left" valign="top"><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p><br />
</td><br />
</tr><br />
</table><br />
<br />
I am trying to code a news type page with a small line between the paragraphs . Thanks in advance for the help!!<!--content-->Well I tried this with a color instead of a gif and it looks horrible. Even with a width of 1 it is huge. Help.....<!--content-->for one you used valign="top". take that out as you want it to go all the way down.<!--content-->Yep:<br />
<table border="0" cellspacing="0" cellpadding="1px" width="100%" align="left" valign="top"><br />
<tr><br />
<td width="50%" align="left" valign="top"><br />
<table cellspacing="0" cellpadding="5"><br />
<tr><br />
<td><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p></td><br />
</tr><br />
</table><br />
</td><br />
<td width="1 px" align="center" valign="top" height="100%" bgcolor="#7f0000"></td><br />
<td width="50%" align="left" valign="top"><br />
<br />
<table cellspacing="0" cellpadding="5"><br />
<tr><br />
<td><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p></td><br />
</tr><br />
</table><br />
<br />
</td><br />
</tr><br />
</table><br />
=========<br />
<br />
cellpadding="1px" you are using cellpadding="5"<br />
<br />
:rocker:<!--content-->Make sure that the <td> ... </td> tags are on the same line as the code that they enclose.<!--content-->and another way to acheive this would be to use css borders, ie:<br />
<br />
<td style="border-left: #000000 1px solid;"><br />
<br />
:)<!--content-->Originally posted by leoo24 <br />
and another way to acheive this would be to use css borders, ie:<br />
<br />
<td style="border-left: #000000 1px solid;"><br />
<br />
:) <br />
<br />
.... that's<br />
nice<br />
quick<br />
and easy leoo :chef: <br />
<br />
:rocker:<!--content-->that's exactly what i was going to recommend. CSS can do 90% of everything under the sun. i even used CSS to pry off my old rusty muffler pipe on the Dart!<!--content-->Originally posted by transmothra <br />
that's exactly what i was going to recommend. CSS can do 90% of everything under the sun. i even used CSS to pry off my old rusty muffler pipe on the Dart! <br />
<br />
<br />
:rofl:<!--content-->Thanks for the tips guy. It still isn't working. I use "class" tags with the css file. I tried a class tag and style tag on the external css and still only a dot. Grrr....Will keep at it.<!--content-->did you do it like this?<br />
<br />
in your css<br />
<br />
td.1 {border-left: #000000 1px solid;}<br />
<br />
<br />
<td class="1"><br />
<br />
this being the td on the right becuase i used border-left, try changing the thickness)<!--content-->Yes I tried that and nothing. Something isn't quite right....<!--content-->I have it working with Peter V's suggestion but I prefer to put as much as possible in an external css file. There is something I am missing. Been looking at this thing too long. Thanks again for the help everyone!!<!--content-->try putting it locally <br />
<td style="border-......"><br />
<br />
do you have a url?<br />
<br />
here, i've just used peter's, cut out the nested tables and it works fine<br />
<br />
<table cellspacing="0" cellpadding="5"><br />
<tr><br />
<td><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p><br />
</td><br />
<br />
<td width="50%" align="left" valign="top" style="border-left: #000000 1px solid;"><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p></td><br />
</tr><br />
</table><!--content-->I don't think you can use numbers for class names.<!--content-->Well it is working for me....<br />
<br />
<table border="0" cellspacing="0" cellpadding="5" width="100%" valign="top" align="center"><br />
<tr><br />
<td width="50%" align="left" valign="top" class="1"><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p><br />
</td><br />
<td style="border-left: red 1px dashed; " valign="top" height="100%"> &nbsp;</td><br />
<td width="50%" align="left" valign="top"><br />
<p>:: Headline</p><br />
<p><br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff stuff<br />
</p><br />
</td><br />
</tr><br />
</table><br />
<br />
======<br />
with class -first td-<br />
and inline style -second td-<br />
<br />
:rocker:<!--content-->yeah peter i have no problems in getting working either?<br />
<br />
scoutt, although i don't use numbers in my own class names, just for quick examples on here.<br />
I've scoured the w3 archives and yes you can use alphanumeric class names, although with the css1 spec you shouldnt start the class name with a number, with css2 you can.<br />
<br />
So anyone who has used any css i have given them please don't start your class names with a number<br />
And i won't use numbers in my examples anymore :)<br />
<br />
little snippet about it:<br />
<br />
in CSS1, class and ID names may not begin with a digit. Since invalid selectors cause rules to be ignored, Navigator correctly acts as though the rule doesn't exist. <br />
<br />
Under CSS2, on the other hand, selectors can start with digits, so Explorer sort of gets away with a technicality, even though it was released before CSS2 had been finalized.<!--content-->
 
Back
Top