add subdomain
Hello,
I have a hosting account on Centos with cPanel. I would like to offer free subdomains to my customer. I can add a subdomain in cpanel, and it works fine. The questions is, How can I make a script that would do that automaticly. All I need is a script that would add it thru shell. I would do the rest. Thanx. |
Might not be your solution but I offer to clients asking for it automatic subdomains. All it takes is a wildcard entry in their dns record and a very simple rewrite rule in their virtual host entry in apache. Then, the simple creation of a directory creates the subdomain.
Here is an example for domain blabla.com. DNS zone file contains: Code:
$ttl 86400 Code:
<VirtualHost *:80> |
All times are GMT -5. The time now is 08:26 PM. |