Hi All,
I get strange permission problems with fopen() ...
$directory = somedir;
$filename = $directory . /somefile.txt;
$handle = fopen($filename, w);// gives: failed to open stream: Permission
denied
but,
- fileperms($directory) gives: 0777 and is_writable($directory) gives writable
-
Hi All,
I get strange permission problems with fopen() ...
$directory = somedir;
$filename = $directory . /somefile.txt;
$handle = fopen($filename, w);// gives: failed to open stream: Permission denied
but,
- fileperms($directory) gives: 0777 and is_writable($directory) gives writable
On Fri, Nov 7, 2008 at 8:35 AM, Richard Heyes [EMAIL PROTECTED] wrote:
So I guess that making somefile.txt with PHP is not possible for Win XP
Er, no. But the permissions system on Windows is greatly different to
Unix. You could make it (and the containing directory) world
writeable, and work
I'm testing on Windows XP SP2 with PHP 5.2.0
That may be your problem. You may want to try a Unix based OS.
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated November 1st)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
On Fri, 2008-11-07 at 14:27 +0200, Thodoris wrote:
I'm testing on Windows XP SP2 with PHP 5.2.0
As far as I remember, you need to pass the b parameter to Windows as
well on fopen(), so you would do an fopen(/path/to/file,wb);
--Paul
All Email originating from UWC is covered by disclaimer
So I guess that making somefile.txt with PHP is not possible for Win XP
Er, no. But the permissions system on Windows is greatly different to
Unix. You could make it (and the containing directory) world
writeable, and work backwards from there (ie making it not so world
writeable).
--
Richard
Andrew Ballard a écrit :
Once you identify the account, it needs to have Modify (which, for
files, includes Read Execute, Read, and Write) permission on the
file being edited. If the file does not already exist, then that
account needs to have Modify (which, for folders, includes Read
: Friday, November 07, 2008 1:29 PM
Subject: Re: [PHP] permission failure with fopen
I'm testing on Windows XP SP2 with PHP 5.2.0
That may be your problem. You may want to try a Unix based OS.
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated
] permission failure with fopen
On Fri, 2008-11-07 at 14:27 +0200, Thodoris wrote:
I'm testing on Windows XP SP2 with PHP 5.2.0
As far as I remember, you need to pass the b parameter to Windows as
well on fopen(), so you would do an fopen(/path/to/file,wb);
--Paul
9 matches
Mail list logo