This is Interesting: Free Magazines for Graphics designers and webmasters
Home > Archive > Stylesheets > December 2006 > image gallery in <ul>: vertical alignment
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
image gallery in <ul>: vertical alignment
|
|
|
| I have a simplified version of my image gallery at:
http://www.niksally.f2s.com/upload/...ed_gallery.html
Essentially, the format of the html is an in-line list:
<ul>
<li><img></li>
<li><img></li>
</ul>
At present, portrait and landscape images are bottom-aligned, which
looks a little funny. Is it possible to have them centre-aligned? I
could relatively easily add a class to the <li> to denote portrait or
landscape arrangement.
The long dimension or each image is 120px, but not all aspect ratios are
exactly 4:3.
TIA.
Nik
| |
| Bergamot 2006-12-06, 7:36 pm |
| Nik wrote:
>
> http://www.niksally.f2s.com/upload/...ed_gallery.html
>
> At present, portrait and landscape images are bottom-aligned, which
> looks a little funny. Is it possible to have them centre-aligned?
img {vertical-align:middle}
You might want to add some margins to that, too.
--
Berg
| |
|
| Bergamot wrote:
> Nik wrote:
>
>
>
> img {vertical-align:middle}
>
> You might want to add some margins to that, too.
>
Many thanks.
I'm sure I tried that, but I must have been styling the <li> instead of
the image.
Nik
|
|
|
| | Copyright 2003 - 2008 forum4designers.com Software forum Computer Hardware reviews |
|