Forum Moderators: coopster
I would like to generate subdomain using data from register form on my website (generate subdomain as soon as user complete registration form, no control panel login ) .
Someone tell me that I need shell scripting to control DNS.
How to do something like that?
or
Any exsample?
Thank you.
Be aware that your script must check the created account name to be sure that all characters are valid for use in a subdomain. I'd suggest allowing only letters, numbers, and hyphens in account names. The first character *must* be a letter, and the last character cannot be a hyphen.
Since hostnames are case-insensitive, while some filesystems are not, I'd suggest restricting account names to lowercase-only.
And of course, you must check to be sure that the requested account name is not "www" and that it does not already exist.
See RFC 2396 [faqs.org] for more information on valid HTTP URLs.
Jim