Use javascript to get the viewport height and the image heights.  Then do
the math.

A javascript library such as Prototype or jQuery will make this a lot
easier.

-Richard Aday

On Mon, Mar 9, 2009 at 12:59 PM, Beeker <[email protected]> wrote:

>
> I'm not aware of any CSS-only solution that would allow you to handle
> pagination, even if you were able to dynamically calculate the height
> of the divs' combined total with CSS. Try asking your question on a
> JavaScript list. A server-side language such as PHP might make this
> problem easier as well.
> Good luck!
>
> On Mar 8, 10:54 am, Dave L <[email protected]> wrote:
> > If I have a number of divs that are stacked on top of each other that
> > are of varying heights (b/c they contain photos of varying heights),
> > Is there a way to find out if the total of all the div heights is less
> > than or equal to a pixel value?  I have a page with a fixed height, so
> > I want to be able to show the most photos as possible and if the
> > photos combined height is too large, then use pagination.  Like next
> > 10 photos, previous 10 photos.  I was thinking this may have to
> > involve javascript, but just looking for thoughts.
>
> >
>


-- 
-Richard Aday

--~--~---------~--~----~------------~-------~--~----~
--
You received this because you are subscribed to the "Design the Web with CSS" 
at Google groups.
To post: [email protected]
To unsubscribe: [email protected]
-~----------~----~----~----~------~----~------~--~---

Reply via email to