Help needed

apps

#1

there are 2 things i want to do with my site but im not sure how to do them.

  1. let users upload files to my site

  2. not allow users to be able to download anything off my site without being a registered user

does anyone have any way to do this?


#2
  1. Fairly easy to do but you have to control what users upload. You can use the code from here to do it

http://www.developerfusion.com/show/2892/2/

Please note that there was a security bug in PHP with this sort of thing. I won’t go into details but you should look on php.net at the is_uploaded_file function and read about it. You’ll need to adapt the script to make use of this function. You should also check the mime type of the file, to make sure it’s not a php file that someone could execute on your server.

  1. This one is more tricky. You can edit .htaccess files to disallow anything apart from your domain linking, but I’m not too sure.

#3

That’s not really the question you want to ask. Of course there is a way to do this - everybody else does it already, don’t they?

Short answer: Learn how to program in Perl/PHP/etc and read up on HTTP protocol and Apache web server administration, etc.

Answer that’s a question(s): How much do you know, how much money do you have, and when do you need it done?

Obvious answers:

  1. Perl Form Upload Script Source
  2. Use …htaccess to password protect a Web directory using HTTP Basic Authentication,
    or prevent hotlinking, see Web Admin Panel -> Goodies -> Htaccess/WebDAV

:cool: Perl / MySQL / HTML CSS