CHMOD Question.

XML, Perl, Python, and other languages can be discussed here, even if it isn't PHP (We might forgive you).

Moderator: General Moderators

Post Reply
Dale
Forum Contributor
Posts: 466
Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks

CHMOD Question.

Post by Dale »

What number would i use on a folder, to allow uploads, downloads, but so you cannot delete the files that are uploaded. Possibly not renamed them either (and possibly cannot be re-CHMOD'd).
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

just use an upload/download script. The only options for permissions are read, write, execute for each type on the file system.

You will need to, at least, make the folder read and write to php's user, and you'll probably want read and write access for your user as well (for FTP and junk). So a setting of 0755 is often good enough. Now, if you want to allow direct downloading from the folder, you will need 0757 or similar.
Dale
Forum Contributor
Posts: 466
Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks

Post by Dale »

This has nothing to do with PHP, its a question about a "public" ftp that i'm doing.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

then have two directories. One that's read and execute, the other write permissions..

I believe that's how the old ftp places used to work. They would review the uploads before they became available for download.

To me, it's far easier to handle through PHP on a site.
Dale
Forum Contributor
Posts: 466
Joined: Fri Jun 21, 2002 5:57 pm
Location: Atherstone, Warks

Post by Dale »

feyd wrote:then have two directories. One that's read and execute, the other write permissions..

I believe that's how the old ftp places used to work. They would review the uploads before they became available for download.

To me, it's far easier to handle through PHP on a site.
I know its easier to handle via PHP, however i dont think uploading 15MB files would work well with a 56k modem and uploading via a form.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

it works pretty similarly. You just need to set php to accept long and large uploads, which you can find out how to do by reading the "upload file handling" documentation on php.net
Post Reply