php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #6817 fopen doesn't work with $var ?
Submitted: 2000-09-20 18:43 UTC Modified: 2000-10-16 11:03 UTC
From: carl dot schreiber at web dot de Assigned:
Status: Closed Package: Filesystem function related
PHP Version: 4.0.2 OS: Linux Suse 6.4
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: carl dot schreiber at web dot de
New email:
PHP Version: OS:

 

 [2000-09-20 18:43 UTC] carl dot schreiber at web dot de
Hello,

I'm lost with a problem that I don't really understand,
may it's a bug?
(working on Suse Linux 6.4 & php4)
This way the file is created written and closed:
$fp = fopen("/tmp/zytest.tmp","w");
$i = fputs($fp, "TEST");
$j = fclose($fp);
All results are ok: $fp =..#1, $i=4, $j=1;

This way all the results (echo...) seems to be ok,
but no file is created, no file is in that folder hereafter?
$dfn="/tmp/ztest.tmp";
$fp = fopen($dfn, "w");
$i = fputs($fp, "TEST");
$j = fclose($fp);
The echo.. results are the same: $fp =..#1, $i=4, $j=1;

So if I hardcode folder and filename fopen() works,
if I assign the folder and file to a variable,
nothing happens?
Does anybody know what to do?

Thanks a lot in advance,
Carl

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-09-21 08:36 UTC] sniper@php.net
I tried this (with latest CVS) and it works. Please try latest CVS or snapshot
from http://snaps.php.net/

--Jani
 [2000-10-16 11:03 UTC] sniper@php.net
I can not reproduce. And no feedback.

--Jani
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 14:01:32 2024 UTC