managing subdomains

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Vegan
Forum Regular
Posts: 574
Joined: Fri Sep 05, 2008 3:34 pm
Location: Victoria, BC
Contact:

managing subdomains

Post by Vegan »

I was wondering, given a bunch of base domains, Apache of course can have as many subdomains as you want. No problem. Simply add more and more vhosts.

So given a web form and a simply box, and some code why not store the subdomains in MySQL? Then the code can generate a new httpd.conf file when a new sub-domain is added.

The database idea could be used for redirected sites where Apache does simple redirects to another IP address.

so fields I can think of include the subdomain, domain, and IP
Hardcore Games™ Legendary is the Only Way to Play™
My site is powered by LAMP
Peter Kelly
Forum Contributor
Posts: 143
Joined: Fri Jan 14, 2011 5:33 pm
Location: England
Contact:

Re: managing subdomains

Post by Peter Kelly »

I'm no wizz on this stuff but surely there is more to a subdomain than just adding it to httpd.conf?
User avatar
Vegan
Forum Regular
Posts: 574
Joined: Fri Sep 05, 2008 3:34 pm
Location: Victoria, BC
Contact:

Re: managing subdomains

Post by Vegan »

I was thinking I should also feed it to BIND so that it will findable on the internet.
Hardcore Games™ Legendary is the Only Way to Play™
My site is powered by LAMP
Post Reply