Ive got PHP 5.1.4 on Apache 2.0 Handler and Win XP OS.
I don't know if that is possible or how to go about doing it, but I need a script that would call a function as soon as a file is added or deleted anywhere in a specific directory (resize images in a photoalbum).
thanks
script that would run when a file changes?
Moderator: General Moderators
build an array of the current files in the directory, store it somewhere. every x seconds or minutes build an array of the directory and compare it to the stored array. then by comparing the arrays you can tell if any files are missing or if new ones are added.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
I was thinking of something more like a trap routine, but I obviously don't know if there is anything even close to that.scottayy wrote:build an array of the current files in the directory, store it somewhere. every x seconds or minutes build an array of the directory and compare it to the stored array. then by comparing the arrays you can tell if any files are missing or if new ones are added.
I thought of doing what you suggested, but I don't know how to execute that code. How do I do that without using a browser?