WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] moving WP to root (9 posts)

  1. ryanoz
    Member
    Posted 6 years ago #

    I'm moving WP from a temp dir to the root dir.
    so... from example.com/temp/ to example.com

    I just did EXACTLY what it says here: http://codex.wordpress.org/Moving_WordPress

    and I can't login to the admin panel. its redirecting me to
    example.com/temp/

    I know it has something to do with permalink structure and .htaccess,
    but I can't login to change the permalink.

  2. Lester Chan
    Member
    Posted 6 years ago #

    What is written in your .htaccess now?

    Did you change the siteurl as well as the home url to reflect the new url?

  3. ryanoz
    Member
    Posted 6 years ago #

    this is in the .htaccess right now:

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

    yes I changed "wordpress address (URL)" and "Blog address (URL)", did exactly what the link above said. Also, I don't use WP as a blog. I use a custom theme and static pages.

  4. Lester Chan
    Member
    Posted 6 years ago #

    try replacing
    RewriteRule . /temp/index.php [L]

    With
    RewriteRule . /index.php [L]

  5. ryanoz
    Member
    Posted 6 years ago #

    made the change. still not working.
    when I try domain.com/wp-admin it goes to this:
    domain.com/temp/wp-login.php?redirect_to=%2Fwp-admin%2F

    if I go to domain.com/wp-login.php it brings up the login page and when I try to login it goes to the same as above.

  6. Lester Chan
    Member
    Posted 6 years ago #

    OH and
    RewriteBase /temp/
    To
    RewriteBase /

  7. ryanoz
    Member
    Posted 6 years ago #

    yea done tried that also. still not working.
    the link above has a link at the bottom to this:
    http://codex.wordpress.org/Changing_The_Site_URL

    which is a whole different set of instructions. I started following these and the 'siteurl' in phpMyAdmin sql is still /temp/ . Shouldn't that have changed when I changed it in the WP panel? I guess I should continue following these "other" steps.

  8. Lester Chan
    Member
    Posted 6 years ago #

    yea for me when I moved to the root, I changed it using phpmyadmin. You need to change 'siteurl' as well as 'home' option name

  9. ryanoz
    Member
    Posted 6 years ago #

    ok. that fixed it.
    Thanks

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.