Click here to Skip to main content
13,249,174 members (33,572 online)
Rate this:
Please Sign up or sign in to vote.
See more:
<table id="tab" width="100%" style="border-right-style: solid; border-right-width: thin" cellspacing="0" cellpadding="0" border="0" >
<td   align="left" width="60%" style="border-right-style: solid ; border-right-width: thin" height="100%" colspan="0" rowspan="0" valign="middle">
 <td  align="right" width="40%" height="100%" colspan="0" rowspan="0" valign="middle">
Posted 7-Nov-12 3:07am
Tadit Dash 7-Nov-12 8:21am
With this code, I cannot find any cell space.
There is no space. They are next to each other.
Bala Selvanayagam 7-Nov-12 8:26am
Are you using style sheet ?

if so, please post the releveant section.
If you load this HTML in the browser, you will see that td are stretched to sided of the window...
Besides, with formally 0 padding + 0 margin still there is a tiny gap, depending on layout engine; I doubt it can be reduced.
Tadit Dash 7-Nov-12 13:10pm
I am unable to find that gap.
Can you please show me that gap in an image ?
How can I show it?
load this to a Browser:


I've chosen MMM and HHH on purpose, to see the gap between M and H. I depends on the layout engine.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Remove all style, width and cellspacing attributes from this HTML, and you will see that the gap is greatly reduced. :-)

Please see my comment to the question.

Next time, never ever do such things. Use CSS and only CSS, and always in separate link or style elements under the head element. How? Well, you did not tell us what rendering you want to achieve. Do it the right way first, and then, if you fail, ask another question, but then describe your goal in detail.

On proper referencing of CSS in HTML documents or embedding them, please see:[^].

To learn styles, start here:[^],[^],[^].

This can be a useful tool for you:[^].

pranathis012 7-Nov-12 23:07pm
sry what i want is to remove the space between two rows
I told you how to do it. Did you get it?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web01 | 2.8.171114.1 | Last Updated 7 Nov 2012
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100