Jump to content

Archived

This topic is now archived and is closed to further replies.

mhoctober

Looping Through Files In A Folder

Recommended Posts

Experts...

I have users upload files (gifs, jpegs etc..) via a form and code that remanes these files, creates a specifically named folder and stores the files therein!

I also have code that can then create

A. a thumbnail and
B. a smaller version of the original file for viewing when the thumbnail is clicked

What I'm missing is code that 'links' the two together.

So - I'm looking for a way to...

1. cycle through all the files in a known folder
2. pass each file to code that creates the thumbnail and reduced file size file - that will create 1 thumbnail and 1 reduced file from each original
3. delete the original files in the folder once 1 & 2 have completed succesfully

Any ideas?

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.