note 45165 added to function.file-exists
| From: | james at vantslot dot net | Date: | Fri, 27 Aug 2004 19:14:16 +0000 |
| Subject: | note 45165 added to function.file-exists | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-75454@lists.php.net to get a copy of this message | ||
How do you test if a file exists if it has a "#" sign in it?
Unfortunately I've got no control over what characters go into the name of a file and need to
test if it exists.
file_exists($filename) fails if the filename contains a "#" sign.
Any ideas how to test the existence of the file and then be able to read it?
I've tried wrapping the base filename in quotes but that doesn't seem to work either.
----
Manual Page -- http://www.php.net/manual/en/function.file-exists.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+45165
Delete -- http://master.php.net/manage/user-notes.php?action=delete+45165&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+45165&report=yes
Search -- http://master.php.net/manage/user-notes.php