Support » Fixing WordPress » How to import to WordPress with media linked to posts?

  • Hi folks,

    I’m in the process of moving my WordPress site from one host to another. Once the move is completed, I’ll be changing the domain name to point to the new server, so all the links referencing my domain will be the same and unchanged from the old site to the new one. The version of WP I have installed in both locations is 3.4.2. I’m having some trouble with exporting and importing my posts intact. Here’s what I’m doing:

    On the old site, I am Exporting all content, using the built-in exporter. My site currently has over 4000 posts, over 9000 comments, and over 3000 tags, so it’s quite a bit of data. I’ve tried doing this as an all at once batch, as well as doing it split into portions by date, but I’m still running into the same problems both ways.

    On the new site, I am Importing that exported file, using the built-in WordPress importer. Everything looks like it works after that. All the posts, comments, etc, show up correctly. The image links still point to the old server, because I didn’t change the web address, but that’s okay because I’ll be FTPing my images folders to the new site, and everything will continue working when I switch the domain over.

    The problem arises with the Media Library. When I do the import, if I select to download the media for the posts, all the images show up successfully in the Media Library list on the new site. However, none of the images are linked to posts like they were on the old site. This messes up galleries that I had set up in old posts, and it also complicates things like Featured Images for each post.

    Could someone help me figure out how to handle this best? Basically, I just want to import all the content of the previous site into the new site with all the media attachments still attached to the correct posts.

    One thing that might or might not be noteworthy is that I’m using the Custom Upload Dir plugin on both the old and new sites. It directs new media uploads to go into daily directories (instead of the default monthly).

    A related issue involves those Featured Images. I previously didn’t use Featured Images, but my new theme does use them. Once I have everything transferred and linked correctly, I’ll need a good way to automatically populate the Featured Image for all 4000+ posts. I’d like to have it do something like just pull the first image in each post as the Featured Image, if that would be possible.

    If someone could direct me to plugins that would help or give me some specific guidance, I’d really appreciate it. And I’ll be happy to provide any additional information that you might need to help me work through this.

    Thanks so much,

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘How to import to WordPress with media linked to posts?’ is closed to new replies.