> "If you create the file, it will return &true; even if you then delete > the file". Are you sure?
Oh yeah! read the Wez comment at http://bugs.php.net/27134 > <?php > var_dump(file_exists('temp.txt')); > touch('temp.txt'); > var_dump(file_exists('temp.txt')); > unlink('temp.txt'); > var_dump(file_exists('temp.txt')); > ?> > > Outputs: > > bool(false) > bool(true) > bool(false) this is because PHP updates the info, but run this script: <? while(true) { var_dump(file_exists('/tmp/foo')); sleep(1); } where /tmp/foo is a file that doesn't exist. Then create the file. and then delete again. Results? false true - when you create the file true - even if you delete the file Nuno
