Link to home
Start Free TrialLog in
Avatar of Mike Waller
Mike WallerFlag for United States of America

asked on

align text next to image in html table

Here is my url: http://advancedeyecaredocs.seozones1.com/dev/

I've placed a table in the content area for an image and the text next to the picture should be vertically aligned with the picture yet the text will not align to the right of the image.

Any idea experts?
Avatar of becraig
becraig
Flag of United States of America image

Why not replace the two table cells with divs

eg div1  div 2 in the same td

<div style="padding-left:20px;">
<table width="619" cellspacing="0" cellpadding="0" border="0" align="center">
<tbody>
<tr class="home_page_copy">
<!-- <td width="135" valign="top" align="left">
<td width="484" valign="top" align="left">-->
<td>
<div id=div1></div>
<div id=div2></div>
</td>
</tr>
</tbody>
</table>
</div>
You should probably start by validating the code, as a lot of the 16 errors seem to be right around where you are having the problem.

Cd&
Avatar of Mike Waller

ASKER

this issue is when I add in image, that the text to the right of the image does align up to the right of the image.
ASKER CERTIFIED SOLUTION
Avatar of Jason C. Levine
Jason C. Levine
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
<div style="padding-left:20px;">
<table width="619" cellspacing="0" cellpadding="0" border="0" align="center">
<tbody>
<tr class="home_page_copy">
<!-- <td width="135" valign="top" align="left">
<td width="484" valign="top" align="left">-->
<td>
<div id=div1 style="float:left;position:relative;top:0;left;"><img src="capture.png"></div>
<div id=div2 >BLAH BLAH BLAH BLAH </div>
</td>
</tr>
</tbody>
</table>
</div>
That did it, thanks!