WordPress.org

Ready to get started?Download WordPress

Forums

WXR Import Screwed Up My Image URLs (5 posts)

  1. dannyfoo
    Member
    Posted 5 years ago #

    I recently had to re-install my WordPress. My original WXR file is 6MB+ therefore I couldn't import it directly due to the 2MB limit.

    I read online we can break the file into several other files as long the header and footer part is maintained. So I did that and managed to import in everything.

    However, I noticed 2 things so far. All my posts were labeled Unpublished. That's 500+ of them. And, my image URLs in all posts with images were screwed up. They now look like this:

    <img src='http://www.dannyfoo.com/blog/wp-content/uploads/2008/11/greenpacket-tour1.jpgwp-content/uploads/2008/10/internet-company-tombstone1.jpgwp-content/uploads/2008/09/google-chrome_minor-tweaks1.jpgwp-content/uploads/2008/08/p1-wimax-launch-161.jpgwp-content/uploads/2008/06/sitemap1.jpgwp-content/uploads/2008/01/wms-20080118-blog-analytics1.gifwp-content/uploads/2007/07/microsoft.thumbnail.jpg' alt='New Microsoft website' class='float-right' />

    I've no idea why is this happening?

    Please give me a solution as I'd like to re-import all of it again. Although I've to re-publish all 500+ of my posts again. Sigh.

  2. @mercime
    Volunteer Moderator
    Posted 5 years ago #

    Suggestions:
    - Make sure you broke the XML files properly - see detailed info here
    - When you re-import thru XML's, check the option to import media files in the panel which appears after you choose the file to import to your WordPress

  3. dannyfoo
    Member
    Posted 5 years ago #

    Thanks Mercrime.

    I noticed one of the XML parts wasn't closed properly.

    Hmm...the weird include is still happening. Argh, have to rechek the whole XML again.

    And I noticed what's weirder.

    Because of 1 wrong import, the other posts are now affected. In other words, all my posts with images now have the above problem. Sigh.

  4. dannyfoo
    Member
    Posted 5 years ago #

    I FINALLY SOLVED IT!

    The reason why it was happening even after I fixed the file, was due to the selected option; Download and Import attachments.

    Every time I tried using this, the second part of the backup I tried uploading for some reason corrupts the anchor/image source as the above.

    Learning this, I uploaded all the backup parts without checking the Import Attachment option and ALL my posts are uploaded as normal.

    ONLY problem now is I've over 500 posts to change their status to Publish again though they've been previously published. Thank you, WordPress.

    If it's any help to the team, I'm using WordPress 2.6.3.

  5. sunshinelove
    Member
    Posted 4 years ago #

    I'm sure this is no help at all after all this time, but I think the XML line you're missing in the import is

    <wp:status>publish</wp:status>

    Without it, your entries will stay in draft mode until you change them by hand or rerun the import with that line in each item.

Topic Closed

This topic has been closed to new replies.

About this Topic