ID: 30253 Updated by: [EMAIL PROTECTED] Reported By: jorisvanmontfort at chello dot nl -Status: Open +Status: Closed Bug Type: IIS related Operating System: windows 2000 PHP Version: 4.3.9RC3 New Comment:
Same as #23069 Previous Comments: ------------------------------------------------------------------------ [2004-09-27 12:21:03] jorisvanmontfort at chello dot nl Description: ------------ When i use the tempnam() function a file is succefully created but it seems that the file is not writeable. I am running php 4.3.9 on IIS 5 as CGI on windows 2000. Reproduce code: --------------- <? // create a tempfile for the thumbnail $tempThumbnailFile = tempnam ("tmp", "thumb"); // write the contents of the zip entry to the tempfile $handle = fopen($tempThumbnailFile, 'a+'); fwrite($handle, $docData); fclose($handle); /* DO SOME PROCESSING ON THE FILE */ // Read the contents of the files into a string. $thumbnailData = fread(fopen($tempThumbnailFile, "r+"), filesize($tempThumbnailFile)); ?> Expected result: ---------------- I expect the a tempfile to be created and I expect to be able to acces this file for write acces in order to manipulate the file contents. Actual result: -------------- Warning: filesize(): Stat failed for C:\Windows\TEMP\thu8450.tmp (errno=2 - No such file or directory) and so on.................. The file is created i can find it in explorer. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=30253&edit=1