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.

Redirect

Discussion in 'General Discussion' started by krigar, Nov 24, 2008.

  1. krigar

    krigar Registered

    Joined:
    Nov 24, 2008
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    I want to redirect my main domain to my subdomain on another domain (this i have manage to do) but I want this "main domain" to stay like "www.mydomain.com" during the whole stay at the homepage, not just redirect to "sub.domain.com"

    Is there some way to do this?

    I have cPanel Version 11.23.6-RELEASE
     
  2. apscinsspl

    apscinsspl Well-Known Member

    Joined:
    Mar 15, 2008
    Messages:
    112
    Likes Received:
    0
    Trophy Points:
    16
    Hello,

    You can do this in a simple way, edit the /etc/httpd/conf/httpd.conf file and change the document root of the domain to that of the subdomain which you want to display when the domain is visited.

    You may get some errors of permission after doing this which can be fixed by setting correct permissions on the subdomain directory.
     
  3. cPanelDavidG

    cPanelDavidG Technical Product Specialist

    Joined:
    Nov 29, 2006
    Messages:
    11,279
    Likes Received:
    8
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    I would advise using Includes rather than editing httpd.conf directly, as described at: http://www.cpanel.net/support/docs/ea/ea3/customdirectives.html
     
Loading...

Share This Page