• Resolved murtrd

    (@murtrd)


    Hello. I exported my data from one location and imported it into another. The categories and comments get imported, but they are not linked to the posts as far as the front end is concerned.

    If I edit a post and update it, all of a sudden all of the posts within that category are properly categorized. Same thing with comments. If I edit a comment for a particular post, suddenly all of the comments for that post appear.

    It wasn’t that big of a problem updating one post per category to get all the categories to propagate correctly for the posts, but with thousands of articles and comments, I really don’t want to do that manually.

    I’m guessing some kind of function could have an array of IDs passed to it and update all the posts at the same time. I’ve searched pretty extensively and haven’t had any luck with any posted solutions out there. Anyone want to help me out?

    I tried to trace through the code a bit and blindly went for

    include('wp-config.php');
    
    $ids = range(1,10000);
    foreach ($ids as $id) {
    	wp_update_post($id);
    }

    in its own file with no luck.

    Thanks!

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Categories and Comments not linking to posts after import’ is closed to new replies.