in reply to How to Seperate Presentation from Implementation with HTML::Template

You can do this kind of thing with just html & css for positioning, just let perl generate the page.
CSS .image { float: right; } img { width: 200px; height: 200px; }
Then perl only needs to generate this for each image:
<div class="image"><img src='foo.jpg'></div>

just another cpan module author

Replies are listed 'Best First'.
Re^2: How to Seperate Presentation from Implementation with HTML::Template
by astroboy (Chaplain) on Jan 12, 2007 at 11:54 UTC

    This is by far the most elegant solution. I, too, have written a gallery that uses H::T, and it used a config setting that specified how many images per row. But that was because I always used tables for layout, and I was never happy with the solution. Now I simply use divs which float to take up the available display space - and gone is the pain of setting up the H::T dimensions as array references of hash references

Re^2: How to Seperate Presentation from Implementation with HTML::Template
by Koosemose (Pilgrim) on Jan 12, 2007 at 10:39 UTC

    Hmm, this just might work, with a little tweaking, maybe some padding, I may well get the effect I wanted. I guess this is a case of me looking for to specific an answer, instead of a solution to a general problem, and also looking on the wrong side for the solution.

    Of course, this goes to show just one of the many things I love about this community, and stayed here so long (I tend to wonder from most places after a couple months). Even though the eventual solution was... off-topic, I suppose, it was offered without the usual sort of shouting that so many other places see. Also goes to show why I'm not in charge of the HTML side of things, my html and CSS are rather rusty.

    Just Another Perl Alchemist