Nightmareinhell Posted August 3, 2011 Share Posted August 3, 2011 Hello! I was wondering, is there anyway to create virtual servers using PHP? Basically what I'm trying to do is... make it so someone can fill out a forum, it will create a folder and files on the server, and then they can point their domain to the server and it will go to the folder. I'm thinking this is done with virtual servers? Is there a way to make this process automated because from my searching it looked like you had to manually edit to httpd config file. Thanks you guys so much for any help! Quote Link to comment https://forums.phpfreaks.com/topic/243647-create-virtual-servers-with-php/ Share on other sites More sharing options...
trq Posted August 3, 2011 Share Posted August 3, 2011 Of course this can be scripted. You can include config files within config files in Apache, so you just create a new config file for each new domain. However, you wouldn't use plain old virtual hosts for this because Apache needs to be restarted for them to take effect. You would need to use mod_vhost_alias. See http://httpd.apache.org/docs/current/vhosts/mass.html Quote Link to comment https://forums.phpfreaks.com/topic/243647-create-virtual-servers-with-php/#findComment-1251012 Share on other sites More sharing options...
Nightmareinhell Posted August 3, 2011 Author Share Posted August 3, 2011 Thank you so very much!! That was most some of my concern also, having to restart apache. Thanks again!! Quote Link to comment https://forums.phpfreaks.com/topic/243647-create-virtual-servers-with-php/#findComment-1251014 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.