in reply to Display all images in a given directory

It's generally a good idea to run code before posting it. Your <href> has a flaw in it.

For style points, use Image::Size to get sizes for HEIGHT and WIDTH tags. That'll make life easier on the browser side.

You might want to make that regex case independent, in case you end up with a .GIF.

Since you're already using CGI.pm methods/subroutines to generate some of your tags, you might consider going all the way.

Replies are listed 'Best First'.
Re: Re: Display all images in a given directory
by cjf (Parson) on Feb 02, 2002 at 04:29 UTC
    Hi,

    I think you must have viewed this just as I was fixing the '-' typo in the href tag (mozilla seems to be having issues with cutting and pasting, so I typed the code out directly into the text field and missed the typo the first time around.)

    I like your suggestion about the Image::Size module, I hadn't heard of it before but I'll definately check it out now. I'll also add on the /i to ignore case as you suggested. Thanks again for the comments :)

    Update: the script now uses the Image::Size module as suggested by dws. Thanks again to everyone for the comments :).