Strange gaps in table cells

This is a discussion on "Strange gaps in table cells" within the Web Page Design section. This forum, and the thread "Strange gaps in table cells are both part of the Design Your Website category.


 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices




Reply
 
LinkBack Thread Tools
  #1  
Old Oct 2nd, 2006, 15:08
Junior Member
Join Date: Aug 2006
Location: UK
Age: 23
Posts: 39
Thanks: 0
Thanked 0 Times in 0 Posts
Strange gaps in table cells

Edit - I think this only occurs in Firefox.

I am making a table for images which are generated from the database, but the layout of them keeps changing.

If you go to - http://www.tessacoleman.co.uk/portraits.asp you may or may not see a small gap under the thumbnail in the cell. I put the border on to show it clearly.

If you press return on the address again (rather than refresh) it should do it again. If you press refresh it should show up okay, without gap. But refresh and then enter the address again - gaps again! Not sure what I'm doing to cause this...

This is my code for the table, if that helps. Thanks.

<%
sql="SELECT id FROM images WHERE category='portraits' AND live='Y' ORDER BY id"
set rs=objconn.execute(sql)

if rs.eof then %>
sorry no results
<%else%>

<table border="1" align="center" cellpadding="0" cellspacing="0" style="margin-top:50px; margin-bottom:50px;">
<%
col=1
while not rs.eof
if col=1 then%>
<tr>
<td width="120"><span class="tessa1"><!--#include file="browse.asp"--></span></td>
<td width="20">&nbsp;</td>
<%
col=col+1
else
if col=2 then
%>
<td width="120"><span class="tessa1"><!--#include file="browse.asp"--></span></td>
<td width="20">&nbsp;</td>
<%
col=col+1
else
if col=3 then
%>
<td width="120"><span class="tessa1"><!--#include file="browse.asp"--></span></td>
<td width="20">&nbsp;</td>
<%
col=col+1
else
if col=4 then
%>
<td width="120"><span class="tessa1"><!--#include file="browse.asp"--></span></td>
<td width="20">&nbsp;</td>
<%
col=col+1
else
if col=5 then
%>
<td width="120"><span class="tessa1"><!--#include file="browse.asp"--></span></td>

</tr>
<tr>
<td width="120">&nbsp;</td>
<td width="20">&nbsp;</td>
<td width="120">&nbsp;</td>
<td width="20">&nbsp;</td>
<td width="120">&nbsp;</td>
<td width="20">&nbsp;</td>
<td width="120">&nbsp;</td>
<td width="20">&nbsp;</td>
<td width="120">&nbsp;</td>
</tr>

<%
col=1
end if
end if
end if
end if
end if
rs.movenext
wend
'finish rows/columns
if col=1 then response.write "</tr>" else response.write "</td><td>&nbsp;</td></tr>"
%>

</table>
<%end if%>
<%rs.close
set rs=nothing%>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote

  #2  
Old Oct 2nd, 2006, 15:28
Junior Member
Join Date: Aug 2006
Location: UK
Age: 23
Posts: 39
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Strange gaps in table cells

It's okay, I managed to find an answer - changing the images to display as block fixed it.

This article is useful for anybody having "gap" problems.

http://developer.mozilla.org/en/docs...ysterious_Gaps
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3  
Old Oct 2nd, 2006, 15:44
Elite Veteran
Join Date: Dec 2005
Location: On Internet
Posts: 4,859
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Strange gaps in table cells

That's Great!!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
spacing, gaps, tables

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Strange table cell height issue niko79 Web Page Design 16 Jun 5th, 2008 10:14
Strange gaps in FF (IE works fine) Donny Bahama Web Page Design 18 May 28th, 2007 15:31
Table Cells magiccupcake Web Page Design 5 Jan 23rd, 2007 01:07
Table help with borders of cells... andrewsco Web Page Design 2 Jun 21st, 2006 22:10
table cells benbacardi Web Page Design 3 Apr 15th, 2004 15:56


All times are GMT. The time now is 18:05.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42