WordPress.org

Ready to get started?Download WordPress

Forums

Media Library: How to fix permalinks after moving WP to root (3 posts)

  1. mbzo2006
    Member
    Posted 5 years ago #

    Recently moved WP out of /blog/ directory to root.

    Managed to S&R the old /blog/ entries left over in the MySql database wp-postmeta table ok.

    BUT, canĀ“t figure out how to fix the thumbnails and image paths in the wp-admin > Media Library.

    I could find only partial hints to solving this question on the forums.
    Mostly guesswork. Nothing authoritative.

    Is this possible?
    If so, what are my options?

    Do I have to keep a duplicate copy of the images in the old blog/wp-content/upload/ folder? Duh..

    Do I have to manually upload a bunch of images (again)? Duh..

    I would appreciate some thoughtful advice on this subject.

  2. kristarella
    Member
    Posted 5 years ago #

    I know this is old now, but for the benefit of anyone else that might search for this (as I did)

    If you're game you can search and replace in your database using the method that Lorelle gave.

    You can use the code she gives for the actual post content and I used the following code the get the thumbnails to show in the media library again (after moving folder from root back to wp-content).

    UPDATE wp_posts SET guid = REPLACE (
    guid,
    'http://www.kristarella.com/uploads',
    'http://www.kristarella.com/wp-content/uploads');
  3. SilkCharm
    Member
    Posted 5 years ago #

    Not sure if it's the same issue, but Media Library paths are held in SETTINGS -> MISCELLANEOUS. I just changed the folder to the new one and it fixed itself.

Topic Closed

This topic has been closed to new replies.

About this Topic