Hi,
I am after a script that will do the SAME as this, <? $path = $SCRIPT_PATH . \"/file.html\"; require \"$path\"; ?>
BUT if the file is in use (being ftped up by the weatherstation) put a error there saying that its updating (insted of a ugly error message)
Thanks
Make that <? echo"<BR>"; $path = $SCRIPT_PATH . "/filename.html"; require "$path"; ?>
Seams the script got stuffed when i posted it,
Have you tried something like
if (file_exists($path) include "$path";
I can't promise it will work, but it's worth a shot. You'll need to use include instead of require for this to have any chance of success.
Hm... doesn't the file exist while it is being uploaded? Maybe you could check if you can get an exclusive read lock on the file. If not, somebody else is locking it (the FTP service).
Yes i know the ftp would lock it,,, Thats why i want a custom error message saying that its updating, insted of error cant open X:\xxx\xxx\x.html ECT,