Hi,
I am planning to host my
website hosting on
VPS Hosting package. Needed to know if you could help me setup
dynamic subdomains on my
VPS Hosting server. Basically, I want to setup dynamic subdomains on the fly without modifying any A records or restarting server any time someone creates a new subdomain. There also needs to be a catch-all for any non-existing subdomain. If you need more details, then please read on.
My requirement is as follows:-
1) Users will register their sub-domain names from frontend
2) imm. after registration; username.mydomain.com should take the surfers to that users page. Also, user should be able to create sub-directories which should map correctly.
like: username.mydomain.com/blogs; username.mydomain.com/forums; username.mydomain.com/parispics etc.
Each registered user needs to have their own login area where they can fully maintain their
website hosting.
That's after some user registers a particular subdomain. Now say; if subdomain has not been registered; typing subdomain.mydomain.com should redirect to registration page.
Here is summary of what I want:
-> When surfer types in subdomain.mydomain.com; Apache should display the correct webpage from (say) /var/www/subdomain else redirect it to registeration page (say /var/www/register.php) if apache detects that subdomain directory does not exists.
Could you help me how to configure apache to do this? Or if this is possible.
Once I have this solution; I'll prepare my scripts and be ready to host.
As I am zero skillset in Apache; it would be great if you could be as specific as possible
So, in essence, Apache needs to capture all subdomains requests.
Warm Regards,
Arun