image alignment challenge!

C

CRON

Hi, Can anyone think of a way to align a bunch of images or divs of
random sizes into a grid where they touch border to border on both the
top and the left hand side? obviously float:left will align them side
by side but is there any way to ignore the line breaks when they wrap
to the following line and align flush with the image above? It's hard
to explain but its quite a simple concept.
 
D

dorayme

"CRON said:
Hi, Can anyone think of a way to align a bunch of images or divs of
random sizes into a grid where they touch border to border on both the
top and the left hand side? obviously float:left will align them side
by side but is there any way to ignore the line breaks when they wrap
to the following line and align flush with the image above? It's hard
to explain but its quite a simple concept.

If there is a landscape on the far left and a portrait that is
taller than the landscape next and so on on one line, then if you
wrap to the next line and the first pic in the wrap to touch the
first pic(in the line above)'s bottom border, what is to happen
to the next pic on the wrap if the one above is a portrait and
juts down?
 
C

CRON

If there is a landscape on the far left and a portrait that is
taller than the landscape next and so on on one line, then if you
wrap to the next line and the first pic in the wrap to touch the
first pic(in the line above)'s bottom border, what is to happen
to the next pic on the wrap if the one above is a portrait and
juts down?

It should simply be aligned to the bottom of the image above it. I'm
only concerned with left and top alignmend - bottom and right can be
ragged. Also I've been thinking for this to be possible at all, the
images must be standard widths: say 100, 200 or 400px so that 2X100px
ones can fit into a 200 one. If this is not the case there will be gaps
in the grid I presume.
 
C

CRON

That's certainly doable, but not if either the width of the
composition, or the order and size of the images, is dynamic.

Hi thanks for the reply. Unfortunately, the width of the composition is
dynamic. The order of images is not.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,051
Latest member
CarleyMcCr

Latest Threads

Top