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.

Cpanel and wordpress

Discussion in 'General Discussion' started by homerwsmith, Oct 18, 2013.

  1. homerwsmith

    homerwsmith Registered

    Joined:
    Mar 19, 2011
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Dear Gentle Folk,

    Problem:

    User has existing domain (say domain.com) pointed to /home/artmat/public_html/index.html.

    They want to create a new site using wordpress on the same domain, but want the old site
    to work until the wordpress site is ready.

    When the new site is ready, they want domain.com to go to the wordpress index.php but NOT show
    the word wordpress in the URL, which happens if wordpress is in public_html/wordpress.

    If wordpress is in the root directory ALONG WITH the old site, it USED to work that the user could call domain.com/index.php
    to see their wordpress site in progress, and domain.com to see the original one. But this no longer works, domain.com/index.php
    seems to recall domain.com and thus domain.com/index.php ends up calling domain.com/index.html.

    Originally when the wordpress site was finished, we could erase the index.html of the original site, and
    the server would find the index.php from wordpress and voila, the new site would be online. This no longer works.

    Thanks in advance to all you guys out there.

    Homer W Smith
     
  2. Tom Risager

    Tom Risager Well-Known Member

    Joined:
    Jul 10, 2012
    Messages:
    107
    Likes Received:
    3
    Trophy Points:
    18
    Location:
    Copenhagen, Denmark, Denmark
    cPanel Access Level:
    Root Administrator
    The word "wordpress" will not appear in the URL once you are ready to set the new site live. Just follow the instructions here: Giving WordPress Its Own Directory « WordPress Codex (under "Using a pre-existing subdirectory install")

    This is a common WordPress question, not specific to websites running on cPanel.
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    You can try adding the following entry to the .htaccess file in your public_html directory:

    Code:
    DirectoryIndex index.html index.php
    Simply remove this line when you are ready to have the index.php file load first, as it appears your hosting provider has configured that as the priority over index.html.

    Thank you.
     
Loading...

Share This Page