jj20051 Posted December 27, 2009 Share Posted December 27, 2009 Hello, I've decided I'm going to build my own control panel, however I need some help getting started. I'm unsure how to make the server give/receive the correct files from each domain. As some of you may know a control panel puts each users files into a folder like this: /users/yourdomain.com/public_html I'm just unsure how to have the server point to those files like this: User requests yoursite.com -> server points them to: /users/yoursite.com/public_html/index.html Any ideas? Quote Link to comment https://forums.phpfreaks.com/topic/186415-building-a-control-panel/ Share on other sites More sharing options...
optikalefx Posted December 27, 2009 Share Posted December 27, 2009 you mean subdomains? like site1.mysite.com? I've never seen site1/mysite.com If that is the case, you need to look into htaccess 301 redirects for certain users to redirect to certain sub domains. However as the server admin you need to make those subdomains point to the right places in apache. Quote Link to comment https://forums.phpfreaks.com/topic/186415-building-a-control-panel/#findComment-984400 Share on other sites More sharing options...
jj20051 Posted December 27, 2009 Author Share Posted December 27, 2009 No the purpose of the script is to host multiple websites not multiple subdomains. Quote Link to comment https://forums.phpfreaks.com/topic/186415-building-a-control-panel/#findComment-984404 Share on other sites More sharing options...
laffin Posted December 27, 2009 Share Posted December 27, 2009 This sounds more like an apache redirect/alias system, than a php issue. Although you can do something like this with php, but apache must be configured for PATH_INFO. Apache Alias look at AliasMatch config setting, which will give you general info on how to use it (although you will need some knowledge of regex) but it should be complicated to add Quote Link to comment https://forums.phpfreaks.com/topic/186415-building-a-control-panel/#findComment-984406 Share on other sites More sharing options...
jj20051 Posted December 27, 2009 Author Share Posted December 27, 2009 Hmm thanks. That seems to be what I need. Quote Link to comment https://forums.phpfreaks.com/topic/186415-building-a-control-panel/#findComment-984410 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.