WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Moving URL from site root (3 posts)

  1. Terminal
    Member
    Posted 4 years ago #

    I installed WP in my root directory, but now I want to move it to a sub directory. It was originally installed to http://mysite.com/ - but I now want to move it to http://mysite.com/blog (I'm now only going to use it as a blog within my website.

    I have altered the wp-config.php by adding two lines to it where "example.com" is the NEW location of my site.

    define('WP_HOME','http://mysite.com/blog');
    define('WP_SITEURL','http://mysite.com/blog');

    =====

    I also changed option_name='siteurl' in wp_options table from http://mysite.com/ to http://mysite.com/blog/ (and back again and tried just with the two included lines to wp-config.php)

    I get the same error regardless of which 'siteurl' I choose in the wp_options table:

    http://mysite.com/blog/wp-login.php = Page not found
    http://mysite.com/wp-login.php = can log in, but then redirects to /blog (page not found)

    I did also try moving the files to a sub-directory prior to trying this, but if I do that I can't even get to the log in page.

    I have followed instructions in the following articles:
    http://codex.wordpress.org/Changing_The_Site_URL
    http://codex.wordpress.org/Moving_WordPress#Moving_WordPress_Within_Your_Site
    http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory

    I know I'm missing something really minor as I can still log in, but form some reason /blog is not showing up as a valid path.

  2. Terminal
    Member
    Posted 4 years ago #

    In addition, if I move site files from root to "blog" subfolder, I get "Error 500 - Internal server error"

    Thanks in advance!

  3. Terminal
    Member
    Posted 4 years ago #

    Changing the login to blog/wp-admin/ solved the problem!
    This what you get for coding into the wee hours! LOL

Topic Closed

This topic has been closed to new replies.

About this Topic