#22065 [NEW]: file() function
| From: | paul dot d dot rowlands at delphi dot com | Date: | Wed, 05 Feb 2003 08:48:23 +0000 |
| Subject: | #22065 [NEW]: file() function | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-32169@lists.php.net to get a copy of this message | ||
From: paul.d.rowlands@delphi.com
Operating system: Windows 2000 server
PHP version: 4.3.0
PHP Bug Type: Filesystem function related
Bug description: file() function
Error log fills with warnings abount the file() function.
Apache 2.0/34
Using php module version 4.3.0 rather than cgi.
Errors.log shows:-
[05-Feb-2003 08:33:45] PHP Warning: file(d:/temp/ht1/050203.ht1) [<a
href='http://www.php.net/function.file'>function.file</a>]:
failed to
create stream: Permission denied in d:\Apache
Group\Apache2\htdocs\fa_tools_ht.php on line 103
Code:-
if(file_exists($file1)==FALSE) die("File1 does not exist");
if(is_readable($file1)==FALSE) die("File1 not readable");
// parse files into arrays
$file_array1=file($file1); //WARNING HERE
if($file_array1==null) die("Permission denied to open file");
--
Edit bug report at http://bugs.php.net/?id=22065&edit=1
--
Try a CVS snapshot: http://bugs.php.net/fix.php?id=22065&r=trysnapshot
Fixed in CVS: http://bugs.php.net/fix.php?id=22065&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=22065&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=22065&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=22065&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=22065&r=support
Expected behavior: http://bugs.php.net/fix.php?id=22065&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=22065&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=22065&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=22065&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=22065&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=22065&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=22065&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=22065&r=gnused