File Upload permissions
Hi,
I want to upload a file and then read it back using a fopen and fread in Custom code. However the permissions are set to 644 on the uploaded file and I don't see any way to change them at the time of upload.
if i run is_readable on the file, i get false, so I expect that is my problem.
The fopen simply returns nothing. It isn't false, or anything else. just null.
Is there any way I can set permissions when the file uploads?
Cheers
Tim
I want to upload a file and then read it back using a fopen and fread in Custom code. However the permissions are set to 644 on the uploaded file and I don't see any way to change them at the time of upload.
if i run is_readable on the file, i get false, so I expect that is my problem.
The fopen simply returns nothing. It isn't false, or anything else. just null.
Is there any way I can set permissions when the file uploads?
Cheers
Tim
Hi Tim,
ChronoForms doesn't set file permissions as far as I am aware. You should be able to change them using a Custom Code action after the Upload Files action - see this StackOverflow answer.
NB The problem may be because (a) you have FTP enabled on the site, or (b) the Joomla! user does not have full write permissions (that's the server user not a registered user).
Bob
ChronoForms doesn't set file permissions as far as I am aware. You should be able to change them using a Custom Code action after the Upload Files action - see this StackOverflow answer.
NB The problem may be because (a) you have FTP enabled on the site, or (b) the Joomla! user does not have full write permissions (that's the server user not a registered user).
Bob
This topic is locked and no more replies can be posted.