|
Convenient web based access to our favorite web design Usenet groups
|
 |
This is Interesting: Free Magazines for Graphics designers and webmasters
| Author |
| Thread |
 |
|
|
|
|
|
 |
 |
 |
can do with a damned table, but not with css! ?? |
 |
|
 |
|
|
|
  07-02-04 - 05:16 PM
|
Hello
I want to do something, i successfully made it with a table, BUT i
really want to do this without, just with pure css...
Want i want is : to add a shadow to a centered picture.
I've found lot of exemple, BUT, each time, they add the float: left;
property that annoye me. I just want it to be centered in the page
(with a little caption bellow).
If i remove the float property, the box expand and the shadow does fit
to the picture box... the only way i've found is to add "display:
table". Of course, this work very well with mozilla but not with IE...
So i manage to have a float: left class (because without, there is no
way to have a box that just fit to its content, and not to the page
width), it is is a table with just a cell. This table is centered in
the page...
So i wanted to know if you knowed a way to do thing like that:
<div class="centeredShadowedPicture">
<img src="link/to/the/picture" alt="text of the picture" />
<div>This is the content</div>
</div>
That display a centered, shadowed picture with a tiny text below...
I tryed :
#content div.centeredShadowedPicture{ border-style: none;
margin: 5px 8px 5px 15px;
padding: 0pt;
background: transparent url(shadow.gif) no-repeat scroll right
bottom;
position: relative;
/*float: left; <-- BEURK!!!!! */
}
#content div.centeredShadowedPicture img {
border: 1px solid rgb(169, 169, 169);
margin: -6px 6px 6px -6px;
padding: 4px;
display: block;
position: relative;
background-color: rgb(255, 255, 255);
vertical-align: bottom;
}
Thanks to all
Great A'Tan
PS: I'm a beginner with css...
|
|
|
| [
Post Follow-Up to this message ]
|
|
|
|
|
 |
|
|
 |
|
|
 |
|
|
 |
| All times are GMT. The time now is 04:30 AM. |
 |
|
|
|
|
|  |
|