Jump to content

I need help with CHMOD and file writing


johnny22

Recommended Posts

Hi, I made a small script that logs my blog's visitors.

 

Here it is:

 

$file = fopen("log.txt", "a");
fputs ($file, "$ip, $host\r\n");
fclose ($file);

 

I CHMODed the file log.txt to 0777 and it's working.

But is it correct? I mean which CHMOD do I have to set for log.txt?

 

Please help me!

Thanks!

Link to comment
https://forums.phpfreaks.com/topic/72407-i-need-help-with-chmod-and-file-writing/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.