[thelist] Image Horizontal Alignment with CSS...
Brian Hurtt
bhurtt at mindspring.com
Mon Dec 8 22:41:16 CST 2003
middle and absmiddle are vertical settings, not horizontal. for horizontal
you want 'center'
-----Original Message-----
From: thelist-bounces at lists.evolt.org
[mailto:thelist-bounces at lists.evolt.org]On Behalf Of Anthony Baratta
Sent: Friday, December 05, 2003 1:11 PM
To: thelist at lists.evolt.org
Subject: [thelist] Image Horizontal Alignment with CSS...
Howdy...
I've stumbled across a problem implementing horizontal alignment to images
that are embeded inside a table cell and a div. Here's a code snip:
<table width="300" border="1" cellspacing="0" cellpadding="0">
<tr>
<td width="1"><img src="/images/spacer.gif" width="1" height="150"></td>
<td><div id='UserContentSpace' name='_203'><img height="299" hspace="0"
src="/images/image.jpg" width="201" align="middle">
</div>
</td>
</tr>
</table>
FYI - The div is part of our CMS application.
Anyway - left and right work, but middle and absmiddle do not. I've tried a
few things:
* If I add a class or an ID to the image, I can manipulate the horizontal
alignment with CSS
e.g.
div#UserContentSpace img#Test {display: block; margin: auto;}
or
.Test {display: block; margin: auto;}
Either of the above only work with Mozilla. IE ignores it. I can't target
the table cell itself due to constraints with the CMS application that
drives this site. I can target the image directly via Class or ID
attributes and CSS.
I've read the CSS specs at W3.org, played with a couple examples at other
web sites, and have come away confused. Any clues are appreciated.
---
Anthony Baratta
President
Keyboard Jockeys
"Conformity is the refuge of the unimaginative."
--
* * Please support the community that supports you. * *
http://evolt.org/help_support_evolt/
For unsubscribe and other options, including the Tip Harvester
and archives of thelist go to: http://lists.evolt.org
Workers of the Web, evolt !
More information about the thelist
mailing list