1
In order to allow my domain/hosting to use dynamic subdomains, I had to create a DNS wildcard (domain.Sub.com).
The problem is that some people usually access using the prefix 'www' before the subdomain, so if I try to access my domain in the following way www.subdominio.com will obviously not resolve and will return error in the browser.
It is possible to configure my hosting/domain so that when the user puts the www
before the subdomain, it redirects to domain.Sub.com? How?
Example of this is Google Plus, if I access www.plus.google.com will redirect to http://plus.google.com.
How is your wildcard configured in the DNS zone? I have some websites that use dynamic subdomains and DNS zones were simply made like this:
* 14400 IN CNAME dominio.com.br.
I just tested it and it solves as many levels as you want before the domain for e.g. www.isso.e.um.teste.dominio.com.br so the rewrite rule they posted below would suffice to work...– Jader A. Wagner
Sorry, I had set up wildcard with type 'A' input and reported the wrong IP, my mistake! Great, now you’re accepting as many levels as you want as subdomain.
– Gustavo Piucco
This question seems to be decontextualized because it is about a specific user error, which will not help other users, and it seems that it has already been even revoked.
– Fernando Leal