A non-intuitive technique for implementing wildcard DNS on CPanel
I've been playing around with Wordpress MU for some time now, but always using the option for installing each blog on its own subdirectory (for example, http://www.example.com/foo/), rather than each blog sitting on its own subdomain (for example, http://foo.example.com). I was doing this because, from what I can tell, my web host, bluehost, doesn't allow shared hosting users to enable wildcard DNS entries through Apache config. I can imagine that they don't want to open the floodgates, and that makes a certain amount of sense.
So I was chugging along with subdirectories, when I found somewhere online a surprising technique to implement wildcard domains through CPanel. I wish I had bookmarked it, because I can't find it now.
It's quite simple. You just
- Go into Cpanel to add a new Sub-domain
[caption id="attachment_4" align="alignnone" width="300" caption="Select 'sub-domains' in Cpanel"]
[/caption] - Simply create a new subdomain called the symbol asterisk. In other words, for the name of the subdomain put *. I don't know if this is intentional on the part of the designers of CPanel, or some kind of bug. But, it seems to create the entry of the form *.example.com that you're (or at least, I was) looking for.
[caption id="attachment_5" align="alignnone" width="400" caption="Put an * into the name field of the new subdomain entry form."]
[/caption]
