views:

87

answers:

2

Hi, in the following HTML snippet, I would like the two cells be placed side by side with NO spaces between them; without using css if possible. If the leftmost position of the 2nd one is the rightmost position of the 1st, why WOULD they have any space between? thx.

  <TR>

  <TD style="position:absolute; top:98px; left:0px; right:56px; bottom:126px; font-size: 7pt; background-color:Lime; text-align: center; font-family: Arial;" cellpadding="0" cellspacing="0">ABC</TD>



     <TD style="position:absolute; top:98px; left:56px; right:112px; bottom:126px; font-size: 7pt; background-color:Lime; text-align: center; font-family: Arial;" cellpadding="0" cellspacing="0">123</TD>
+1  A: 

I'm not entirely sure I understand the question... The space in between them in the source will be ignored by the browser, and should put them next to each other.

Do you want to remove the padding between the cells? Try adding style="border-collapse: collapse" to the <table> element. But even better would be to move your styling over to a css file, since you've got so much going on there.

edit: Ah, now I notice the position: absolute in there. Get rid of that (and the top, right, bottom, and left that go with it).

keithjgrant
+1 - my first thought was `border-collapse`
Russ Cam
Thanks. I wouldn't ordinarily include (top, left, etc) in the TD, but I'm trying to mirror the placement of text data from another application. This other app spits out a data file indicating the position (top, left, etc) of its screen info. Ideally Im looking to get the TDs to act on their TOP ) - thanks
Joe
keithjgrant
+2  A: 

Why absolutely position your table cells? They automatically render next to each other. All you need to do is border-spacing="0" if I remember correctly. It'd be much easier with css though =)

Qwibble