Jump to content

Manage Apache with PHP


tommy117

Recommended Posts

Hi

I'd like to know how to create an Apache user-account with PHP (the idea was to create a folder and a user-account with rights on that folder so that a user (who registered on a PHP page) could use ftp to upload files to the server).

Also, is it possible to make a folder on Apache so that it could be accessed only by the owner and from the web (and by root)?
Link to comment
Share on other sites

  • 2 weeks later...
In order to do this, you'll need to find ways to:

-Have PHP edit the httpd.config to add virtual hosts, directories and aliases for each user.
-Install an FTP service that can be access from the command line (batch file FTP).
-It sounds like you will need to use exec() to have PHP run processes on the command line for interfacing.

In this situation, it would be more practical to use .htaccess files to control access to directories which would be relatively simple.

All in all, this is too complex of a project to step-by-step here and will require a lot of workflow planning. Sounds like your essentially trying to set up a hosting business. If you can't find a command line FTP server (I have none to recommend) you can do a Geocities-like file manager with file uploads, but that is a whole other can of worms. Take a look at the bullets, see if this is practical for you.

Good luck.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.