WordPress.org

Ready to get started?Download WordPress

Forums

site URL change - all ok but homepage? (18 posts)

  1. phendyr
    Member
    Posted 1 year ago #

    Hello,
    I have a instance of wordpress 3.5.1 installed in a subfolder "website" on the server. I'm trying to follow the how-tos on making the URL people use/see just the domain name and not include the sub directory in the URL. All my pages are currently working, images display fine, but the homepage gives me a 'page not found' error. For the life of me I cannot resolve this issue.

    I've tried adding statements to the config.php file, I've looked at the .htaccess files, etc. Nothing seems to get it to work... When visiting the homepage, it automatically adds the subfolder name to the path of the url.

    Any help to point me in the right direction will be greatly appreciated. Thanks in advance.

  2. Kurt
    Member
    Posted 1 year ago #

    What are your settings for WordPress Address & Site Address in the General Settings?

    Have you reviewed Using a pre-existing subdirectory install here: http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

  3. phendyr
    Member
    Posted 1 year ago #

    WordPress address (URL): http://www.mywebsite.com/website
    Site Address (URL): http://www.mywebsite.com

    Yes thank you for that article reference I have been looking at it, and I have confirmed that I copied where I needed to copy files and moved where I needed to move.... a little dumbfounded at the moment.

    Thanks for the feedback.

  4. Kurt
    Member
    Posted 1 year ago #

    What's in your index.php? And is it in the root?

  5. phendyr
    Member
    Posted 1 year ago #

    require('./website/wp-blog-header.php');

    yes it is in the root.

  6. Kurt
    Member
    Posted 1 year ago #

    Hmmm... Perplexing.

    Let's look at the .htaccess file. What's in this file?

  7. phendyr
    Member
    Posted 1 year ago #

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    # END WordPress

  8. Kurt
    Member
    Posted 1 year ago #

    It doesn't look right if WP is running in a subfolder. Go to Settings => Permalinks, click on the Save Changes button. Refresh your browser and see if that fixes it. If not, change the permalink setting to default and save. Refresh your browser to see if it fixes it. Either way, set the permalinks back to what you want.

    If the above doesn't work, edit the .htaccess file and change these two lines:

    RewriteBase /website/
    
    RewriteRule . /website/index.php [L]
  9. phendyr
    Member
    Posted 1 year ago #

    making the change above, and changing the permalinks to default, corrected the issue. after reverting them back to my desired style (post name) the homepage is broken again.

    Thank you for your continued help to debug this. I greatly appreciate it.

  10. Kurt
    Member
    Posted 1 year ago #

    You're welcome.

    Try editing the .htaccess file as indicated previously.

  11. phendyr
    Member
    Posted 1 year ago #

    I have that modification currently in place, as written below, but the homepage is currently not found:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /website/
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . website/index.php [L]
    </IfModule>

    # END WordPress

  12. Kurt
    Member
    Posted 1 year ago #

    It looks like a forward slash is missing in the last rewrite rule. It should be:

    RewriteRule . /website/index.php [L]
  13. phendyr
    Member
    Posted 1 year ago #

    hmm, added that and still no joy. tried resaving permalinks after uploading the .htacess file, no joy.

  14. phendyr
    Member
    Posted 1 year ago #

    .... and it still tries reverting the homepage to the .com/website/ directory... all other pages display correctly at .com/page-name/

  15. Kurt
    Member
    Posted 1 year ago #

    Well, I guess it could be the hosting setup. Does your hosting configuration point to the /website/ folder or to the root?

  16. phendyr
    Member
    Posted 1 year ago #

    good question, I'll dig a little deeper and post what I find.

    Thanks.

  17. phendyr
    Member
    Posted 1 year ago #

    Well the host provider of this client is Network Solutions and they apparently force you to install wordpress into a subfolder.... I've never experienced this before with another host provider. I walked through the process a little bit, and noticed that there's a checkbox for "make this install your homepage".... that must be what's causing my problem - that was checked when WP was installed and now there's something forcing it to that subfolder.

  18. Kurt
    Member
    Posted 1 year ago #

    I haven't set up a site on NS yet. That could be the problem.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.