macworks Posted September 18, 2006 Share Posted September 18, 2006 Okay I'm building a PHP driven document library where users can upload and download documents, create folders, sub-folders, etc.I discovered that I needed to use clearstatcache to force PHP to actually look at the file system to determine if a file exists or if an item is a directory / folder. But when I remove files from the folder, PHP still thinks that the item is there when I use is_readable or is_dir or file_exists. I even went so far as to upgrade PHP from 5.1.4 to 5.1.6 and I restarted Apache too.Does anyone have any insight on this?In case you are wondering, my document library uses a database to store the list of document with some additional meta-data, so when a user visits a doc lib folder, PHP grabs records from the database to see which files are in the directory, then checks the file system to make sure that the files are actually there. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.