This is a discussion on "CSS alignment issue" within the Web Page Design section. This forum, and the thread "CSS alignment issue are both part of the Design Your Website category.
|
|
|
|
|
![]() |
||
CSS alignment issue
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#1
|
|||
|
|||
|
CSS alignment issue
Hey all, am making a picture gallery, and have laid it out in 4 columns for images, given each image a container using list items etc.
Anyways its fixed size, and the image will either be max height or width as 150px so at least one dimension of the thumbnail will fit the container. Basically at the mo I have all images in top left of the container, so all landscape images have space underneath, and all portrait images have space to the right. I need them to be middle / center. HTML
|
|
|
|
#2
|
|||
|
|||
|
Re: CSS alignment issue
Live link here as an example - http://mort.86degrees.com/sites/gall...?view=gallery2
Have fixed the portrait images so they horizontally align, but the landscape ones are all still at the top of their containers Any ideas? |
|
#3
|
|||
|
|||
|
Re: CSS alignment issue
Well here's sort of a shot in the dark.
I found this code on one of the enlarged graphics pages. I added the part in red and it centered the entire table. Does that solve the problem?
|
|
#4
|
|||
|
|||
|
Re: CSS alignment issue
hehe
was going for a table-less layout, been trying to resist using that, wanted to do it all in css if I could |
|
#5
|
|||
|
|||
|
Re: CSS alignment issue
Oh sorry... missed that part of the post apparently!
Well I'll try to see if I can figure out something tomorrow! Centering along the horizontal is easy... that's simply margin: 0 auto; Centering along the vertical is more difficult. I don't know that off the top of my head. I'd have to google it. I know there have been posts on this forum with complete explanations too. |
![]() |
| Tags |
| alignment, css, database, gallery |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [SOLVED] CSS Alignment Issue | AaronSmith | Web Page Design | 5 | Jan 23rd, 2008 14:21 |
| Alignment Issue | keydin | Web Page Design | 2 | Aug 24th, 2007 01:37 |
| Alignment issue in table with multiple select | peacher | Web Page Design | 2 | Aug 23rd, 2007 07:35 |
| Alignment in IE | technicolourchameleon | Web Page Design | 4 | Oct 11th, 2006 22:59 |
| Alignment issue with header | WillisTi | Web Page Design | 1 | Jan 31st, 2006 16:20 |