On Tue, Aug 13, 2002 at 04:02:51PM -0230, Kondwani Spike Mkandawire wrote:
$file = fopen(Counter.txt, r+);
$counter = fread($file, filesize(Counter.txt));
fwrite($file, $counter, strlen($counter));
... snip ...
// For some reason the updated value is not written
// to Counter.txt
Any idea why this is not working...
$file = fopen(Counter.txt, r+);
$counter = fread($file, filesize(Counter.txt));
fwrite($file, $counter, strlen($counter));
echo 'form name=studVer action = ThisSameFile.php method=post';
if(empty($SomeVariable...)){
$counter++;
// Here counter
$file = fopen(Counter.txt, r+);
You need to open the file with write access and PHP must have write
permission
e.g. $file = fopen(Counter.txt, w+);
Mike D...
--
Mike Dunlop
Webmaster
Animation World Network
[EMAIL PROTECTED]
http://www.awn.com
(323) 606-4238 office
(323) 466-6619
3 matches
Mail list logo