Change File Permissions (chmod) with FTP
If you have PHP and CGI scripts on your web server that use text files to store data, you need to have writable permissions, if they want to access a file.
In case those files are not writable, you will probably get this kind of error message (PHP):
Permission denied in [file name] ...
Most - if not all - FTP clients make possible to change the file permissions.
That can either be done with a command line and the command chmod or with some clicks on menus and checkboxes.
FTP programs: CuteFTP | Voyager FTP | Leech FTP | Total Commander (Windows Commander) | WS FTP
Set file permissions with chmod and the command line
The syntax of the command chmod is:
chmod [numeric value] [file name]
The numeric value to make a file writable is 777 and the file name is logfile.txt for example:
chmod 777 logfile.txt
Set file permissions with your FTP program
Connect to your web server via the internet and browse to the file you want to change.
Please follow then the instructions that are below each screen shot (click image to enlarge).
FTP programs: CuteFTP | Voyager FTP | Leech FTP | Total Commander (Windows Commander) | WS FTP
CuteFTP
Step one: Right mouse click on the file => Select "Properties/CHMOD" from context menu.
Step two: Enter either the number "777" in the field "Permissions" or select all checkboxes.
FTP Voyager
Step one: Right mouse click on the file => Select "Properties" from context menu.
Step two: Enter either the number "777" in the field "Numeric Value" or select all checkboxes.
Alternative
Step one: Right mouse click on the file => Select "Commands" from context menu => Select "Change File Attributes..." from the second context menu.
Step two: Enter the chmod command with your file name: chmod 777 your_file.txt
Leech FTP
Step one: Right mouse click on the file => Select "Set Attributes ..." from context menu.
Step two: Enter either the number "777" in the field "Numeric" or select all checkboxes.
Total Commander (Windows Commander)
Step one: Select file from the list => Select "Change Attributes ..." from menu "Files" (upper left corner of the program window).
Step two: Select all checkboxes.
Alternative
Enter in the field below file list the chmod command with your file name: chmod 777 your_file.txt
WS FTP
Step one: Right mouse click on the file => Select "Properties" from context menu.
Step two: Enter either the number "777" in the field "Numeric Value" or select all checkboxes.
Alternative
Enter in the fields right beside the file lists the chmod command with your file name: chmod 777 your_file.txt