WordPress.org

Ready to get started?Download WordPress

Forums

Importing posts from another WP Blog (14 posts)

  1. Mark (podz)
    Support Maven
    Posted 9 years ago #

    http://www.tamba2.org.uk/wordpress/backup/
    That works for moving data in and out of the db.
    Did you literally just download the db, and all the folders then move them ?

  2. CeeJayCee
    Member
    Posted 9 years ago #

    No, I installed a completely clean WP into the new domain. I've decided now thought that I would like the old posts.
    I'll try the link you've posted and get back to you

  3. CeeJayCee
    Member
    Posted 9 years ago #

    I installed the backup/restore script, and uploaded the .sql file which had the wp_posts table from the old database. The restore function said it worked correctly and all posts seem to have been restored correctly.
    However, when I view an old entry which I imported from the old database I get the following before any other output is made:
    Warning: Invalid argument supplie for foreach() in /home/harmonic/public_html/wp-blog-header.php on line 478
    See here for the error: http://harmonicechos.com/archives/somewhere-with-the-wind
    A new entry that doesn't include the error:
    http://harmonicechos.com/archives/ucas-personal-statement
    I have copied the wp_categories table across from the old database, but I presume this is because I haven't copied the old wp_post2cat table across? Is there any way to rebuild this? or do I have to manually enter the post numbers etc?

  4. CeeJayCee
    Member
    Posted 9 years ago #

    Does anyone have any ideas on this?

  5. michan
    Member
    Posted 9 years ago #

    You should have backed up the DB in your old site and restored it to the new one using the version of WP you used before and then upgrade to the new one before writing your new entries.
    I'm not making sense.

  6. dss
    Member
    Posted 9 years ago #

    couldn't you just manually install the posts?
    dunnoe what the bd commands would be, but unless there are hundreds of entries it is an option, at least.
    f.

  7. moshu
    Member
    Posted 9 years ago #

    Your main problem will probably be having identical (post)ID numbers in both databases...

  8. CeeJayCee
    Member
    Posted 9 years ago #

    That's what I was thinking. I don't really want to (or have time to) enter all the posts manually.
    I suppose the best thing to do, would be to import the old domain posts (ceejaycee.net) into a clean database - then manually enter the new domain posts (harmonicechos.com) by hand. Unless anyone can think of anything better.

  9. AlHo
    Member
    Posted 9 years ago #

    No idea as I've never used it myself, but might the rss import work?

  10. cloudless
    Member
    Posted 9 years ago #

    I've used RSS import to backup and restore my WordPress entries. It works. Make sure you increase the number of entries in your RSS feed first.

  11. carthik
    Member
    Posted 9 years ago #

    As a temporary measure, till wp has an xml import-export, you can use the export to mt format script, and then use the normal import-mt.php.
    So the idea is, you use the script to export the wp posts in a text file in the mt format, and then import it using import-mt.php
    You can find the scripts at papascott, and you can find my version at the following url:
    http://blog.carthik.net/wpexportv2.phps

  12. CeeJayCee
    Member
    Posted 9 years ago #

    Thanks 2fargon. I'll try this later tonight :)

  13. CeeJayCee
    Member
    Posted 9 years ago #

    Just thought I'd update this to say, that I eventually got round to trying the import to mt, import to wp method and it worked!

    Thanks to all that helped :)

  14. RustIndy
    Member
    Posted 9 years ago #

    You know, I've been trying to figure out how to do this for about a week now. I'm in almost exactly the same situation as CJC was, but I was getting ready to roll my own solution - kind of as a PHP excercise.

    But no point reinventing the wheel if it ain't broke :)

    Soooo, 2fargon, when I run your script on me blog (the old one, this is), it looks like it's getting all the posts and comments, but the very last line is a MySQL warning about mysql_affected_rows(). Issat normal?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.