Topic awaiting preservation: image viewer (Page 1 of 1) |
|
---|---|
Nervous Wreck (II) Inmate From: |
posted 01-02-2002 03:43
What is a good way to make a page that views images? So far I already wrote perl script that looks in the folders 1 level deep of the current, and makes a webpage of thumbnails for each. Right now when you click on the thumbnail, it links to itself so you see the picture. But it's with the default white background. What's a better way? code: /fooa
|
Paranoid (IV) Mad Scientist with Finglongers From: Germany |
posted 01-02-2002 17:20
well, I ain't no perl programmer, but for 1), why don't you just output a link to the actual image file on the image on the thumbnail page. that way the browser will display just the image when someone clicks the thumbnail. |
Nervous Wreck (II) Inmate From: |
posted 01-03-2002 01:39
quote: That's what i'm doing right now. I didn't do the second suggestion because I don't have a server installed. (That way if i put this on a cd it will still work) |
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 01-03-2002 02:06
Question: How are you going to get the Perl to run if there is no server? |
Maniac (V) Inmate From: Brisbane, Australia |
posted 01-03-2002 05:07
quote:
|
Nervous Wreck (II) Inmate From: |
posted 01-03-2002 23:19
I know perl is serverside, i just explained my question wierd. I'll try again |
Paranoid (IV) Inmate From: Minneapolis, MN, USA |
posted 01-07-2002 17:53
Well I don't know Perl well enough to write out actual code for you, but a recursive function should generally look like this: |
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 01-07-2002 18:25
Yeah I did a bit of checking and there doesn't really seem to be a built in function for this so you will need to parse the files within a directory and fine which are directories and dig into those. |
Nervous Wreck (II) Inmate From: |
posted 01-08-2002 01:59
I got it to work using File::Find. Now I just need to make thumbnails. I downloaded ImageMagick for that. |