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.

Root directory for add-on domain?

Discussion in 'General Discussion' started by GuyScharf, Jul 31, 2012.

  1. GuyScharf

    GuyScharf Registered

    Joined:
    Mar 19, 2010
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    When creating an addon domain, cpanel defaults to /public_html/addon.com for the root directory for the addon domain. This results in the root directory being /home/acct/public_html/addon.com.

    What are the pros and cons of using /addon.com as the root directory instead of /public_html/addon.com? (for a normal shared hosting account, not a reseller account) This would make the root directory for the addon domain be /home/acct/addon.com instead of /home/acct/public_html/addon.com.

    This seems to me to give better separation between the primary and addon domains, but I don't understand if there are other risks or advantages of either approach.

    Thank you!
     
  2. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    14,450
    Likes Received:
    195
    Trophy Points:
    63
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    Not sure there are any downsides (cons) to this. Pro might be that you won't find domain.com/addon.com via search.
     
  3. cPanelTristan

    cPanelTristan Quality Assurance Analyst
    Staff Member

    Joined:
    Oct 2, 2010
    Messages:
    7,623
    Likes Received:
    21
    Trophy Points:
    38
    Location:
    somewhere over the rainbow
    cPanel Access Level:
    Root Administrator
    The pro would be that you can't reach the folder using maindomain.com/folder, since it would only be in the subdomain/addon folder location. Some people wouldn't want their addon folder spidered as a duplicate by search engines under their main domain, which could possibly happen if you place it inside public_html

    This is likely what Infopro was also stating, but to provide an example to see it. I added two domains to my endar.org main domain:

    bestgarden.net
    errorcodex.com

    I did bestgarden.net like this:

    /home/endar/public_html/bestgarden.net

    I can reach it using http://endar.org/bestgarden.net under my main domain

    For errorcodex.com, I did it like this:

    /home/endar/errorcodex.com

    I cannot reach it using http://endar.org/errorcodex.com under my main domain.
     
Loading...

Share This Page