Create file!

From: Date: Mon, 28 Oct 2002 14:25:11 +0000
Subject: Create file!
Groups: php.windows 
Request: Send a blank email to php-windows+get-16589@lists.php.net to get a copy of this message
Hi (Win2000, PHP 4.0.6 IIS) $filename="streets.dat"; if (file_exists($filename)) { Read From File; Print To Html; } else { $f=fopen($filename,"w"); read from database to file; Print To Html; fclose($f); } But fopen will not create $filename, and i get an error like: You dont have permission to create file ... Although the manual says: 'w' - Open for writing only; place the file pointer at the beginning of the file and truncate the file to zero length. If the file does not exist, attempt to create it. How to simply create file in php? Radovan

« previous php.windows (#16589) next »