The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Wildcard subdomains

Discussion in 'General Discussion' started by royli57, Apr 1, 2005.

  1. royli57

    royli57 Active Member

    Joined:
    Mar 3, 2005
    Messages:
    41
    Likes Received:
    0
    Trophy Points:
    6
    Hi everyone

    I did a search for wildcard subdomains but did not find anything that answers my question.

    I want to set up wildcard subdomains that all resolve to my server. I have a blog program that will generate blogs in the format "blogname.mydomain.com." I have edited the DNS zone for that domain to look like: "* 1440 in A {myip}."

    I have read that I also need to modify the httpd.conf file for it to work. If this is the case, what do I put into the httpd.conf file and how do I edit it? Can I just stick the code in .htaccess files instead?

    thanks for the help.

    Roy
     
  2. Gavster

    Gavster Active Member

    Joined:
    Apr 3, 2002
    Messages:
    26
    Likes Received:
    0
    Trophy Points:
    1
    Hi Roy -

    You need to add this to the ServerAlias directive under the VirtualHost container for the domain in question:

    *.domain.com

    Then restart apache - either from within WHM or from the command line:

    /scripts/restartsrv_httpd
     
  3. powerflash

    powerflash Active Member

    Joined:
    Nov 1, 2004
    Messages:
    34
    Likes Received:
    0
    Trophy Points:
    6
    ... and subdomains ftp. , mail. ... smtp. etc.. ??? this is works??
     
Loading...

Share This Page