I'm attempting to create a very simple counter script. It opens the file and increments the count fine, but when I try to reopen the file to write the new count to it, I get a permission denied error.
Warning: fopen("countlog.txt","w") - Permission denied in c:\inetpub\wwwroot\future\count.php on line 15
Line 15 is this: $fp = fopen("countlog.txt","w");
I've tried other flags with no difference. The server I'm publishing to is on our network, Win2000 with IIS5, and I have full administrator rights to it. When I look at the folder permissions tab, I have permission for everything (all boxes are checked). When I look at the file permissions tab, it is the same thing. That to me indicates that there should be no problem with me writing to the file. The text file was created just a few minutes ago in notepad, by me. So what could be the problem??? Does it have to be created by the PHP script instead? If so, any insight into how I should do this? I would write to a database if I could, but it isn't an option right now. PHP on Windows can be frustrating at times.