ID:               20215
 Comment by:       webmaster at onmyway dot cz
 Reported By:      admin at serveurperso dot com
 Status:           No Feedback
 Bug Type:         Filesystem function related
 Operating System: Windows 2000
 PHP Version:      4.3.1-dev
 New Comment:

Had this error too, spend hours figuring it out, finally wrote an
entire page about it to post here and during testing I found this was a
misconfiguration in .htaccess

Hope this helps anyone experiencing the same error. Enjoy


Previous Comments:
------------------------------------------------------------------------

[2007-07-18 07:01:24] mufd2002 at hotmail dot com

I can't reproduce the problem using PHP 4.3RC1 or the slightly more up
to date PHP 4.3 development branch and
the script that you provided, either under win XP with IIS
or linux.

I'm using php.ini-recommended, so please make sure that
you don't have any zany settings turned on in your php.ini or server
configuration.

------------------------------------------------------------------------

[2003-02-25 02:04:34] [EMAIL PROTECTED]

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.



------------------------------------------------------------------------

[2003-02-19 19:39:13] [EMAIL PROTECTED]

What if you write the file in 'wb' (binary) mode? Does
it make any difference? 


------------------------------------------------------------------------

[2003-02-11 15:57:26] 6th at katiusha dot com dot ru

Funnily, 
the bug occurs when I run php as a module. When I run php using cgi or
commandline, no excess 0D symbols appear.

------------------------------------------------------------------------

[2003-02-11 15:40:50] 6th at katiusha dot com dot ru

PHP 4.3.0 (build Dec 27 2002)
Apache 1.3.23
Win ME

This:

$f=fopen("bug","w");
fwrite($f,"test
"); // 74 65 73 74 _0D 0A_
fclose($f);

creates file:

74 65 73 74 _0D 0D 0A_

I'm using plain files with ms-dos line breaks to store databases, so
fwrite is _very_ important for me to work correctly.

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/20215

-- 
Edit this bug report at http://bugs.php.net/?id=20215&edit=1

Reply via email to