ID:               41094
 User updated by:  speakus at mail dot ru
 Reported By:      speakus at mail dot ru
-Status:           Bogus
+Status:           Open
 Bug Type:         Filesystem function related
 Operating System: winXPsp2
 PHP Version:      5.2.1
 New Comment:

code:
<?php
file_put_contents("debug.txt", "text", FILE_APPEND);
?>
work - absolutely correcly - create/update the file
but submited code - is not.
I think it is not possible in simple case "other working directory" ;)


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

[2007-04-15 17:44:39] [EMAIL PROTECTED]

Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. 

Thank you for your interest in PHP.

Apache changes the working directory to / so you\'re actually writing
to /debug.txt.

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

[2007-04-15 15:49:46] speakus at mail dot ru

Description:
------------
I reproduce problem only if PHP Installed as an Apache module!
No issue on php-cgi


Reproduce code:
---------------
<?php
function Shutdown()
{
  file_put_contents("debug.txt", "text", FILE_APPEND);
}
register_shutdown_function('Shutdown');


Expected result:
----------------
file "debug.txt" updated/created with text

Actual result:
--------------
no file created or no updated file


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


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

Reply via email to