...

View Full Version : Trouble with Tables



mafunk
01-16-2003, 10:39 AM
I'm totally frustrated and hoping that one of you can help. So, here's the deal. I'm trying to build a web site that consists ofa white table on a grey background, with an image on the right hand side (ala gettyimages). The trouble is the right-hand cell (the one in which I have an image) has a bit of extra white space around it (or blue, or yellow, or whatever color I code in for the background color. The cell is 304 pixels wide, as is the image that I'm inserting. Below is the code? Any suggestions?

BTW - as per on of your suggestions, I went to tucows and downloaded coffeecup html. Thanks for the idea.

<body bgcolor="#66666" text="#333333" link="#008000" vlink="#008000" alink="#008000">
<CENTER>
<TABLE WIDTH="100%" HEIGHT="100%" >
<TR VALIGN="MIDDLE" ALIGN="CENTER"><TD >

<TABLE WIDTH="700" CELLSPACING="0" CELLPADDING="0" border="0">

<tr><!-- Row 1 -->
<td width="394" bgcolor="ffffff" > </td><!-- Col 1 -->
<td width="304" bgcolor="ffffff" ><img src="images/rapper.jpg" width="304" height="378" border="0" align="right"> </td><!-- Col 2 -->
</tr>

</TABLE>
</TABLE>

</CENTER>
</BODY>

Thanks,
MaFunk

ronaldb66
01-16-2003, 11:32 AM
I tried ditching cell dimensions on the cell holding the image, and forcing the adjacent cell to match up width a width="100%" setting; no background color visible... Dunno if the forcing bit works on every browser, though.

P.S. Oh, and the extra space after the img element might cause trouble as wel; I removed it, anyway.

nickbarresi
01-16-2003, 02:51 PM
I found a few things that could be causing problems...

<TR VALIGN="MIDDLE" ALIGN="CENTER"><TD >

Add the attributes to TD not TR.

<td width="304" bgcolor="ffffff" ><img src="images/rapper.jpg" width="304" height="378" border="0" align="right"> </td>

remove the space between the img src and </td>

hope this helps!

justame
01-16-2003, 09:12 PM
maf...
"quote...<TABLE WIDTH="700" CELLSPACING="0" CELLPADDING="0" border="0">

<tr><!-- Row 1 -->
<td width="394" bgcolor="ffffff" > </td><!-- Col 1 -->
<td width="304" bgcolor="ffffff" >...endquote"

ummm your 'tds' only just a total® 698 n' youve got your 'table' set to be 700...
n' tooo???
you just a forgot® the # infront of the ffffff

n' just a nother® tooo???
dont have just a linebreak® between your td's...
aka...
<tr><td>yadda yadda...</td><td>img goes here...</td></tr>

just a goodluck® :O)))

mafunk
01-17-2003, 04:23 AM
You guys are awesome! Thanks for the suggestions. I tried all of them, and changed the code to "align="absright". Whala! It's all set.

Thanks again.

MDF
:thumbsup:



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum