Support » Fixing WordPress » Problem with comment user_id after import!

  • jenseo


    I recently changed web host from one place to another, and then i exported/imported all my content, posts, pages, comments and so on from my old blog to my new one.

    I have now found a problem! In my comments template, I’m using: <?php if ($comment->user_id) to assign a css class to be able to highlight author comments. The problem is that it seems all my imported comments weren’t assigned any user id at all, or at least that’s what I’m suspecting, since none of my author comments from my old blog now are highlighted!

    Any suggestions on solutions for this?

    By the way, I’m using version 2.6.3 at the moment.

    // Jens.

Viewing 6 replies - 1 through 6 (of 6 total)
  • jenseo



    No one that can think of a solution? Is it possible for me to assign my user_id to posts or something like that? Through phpmyadmin perhaps?

    // Jens.



    Assign my user_id to comments was of course what i meant!

    Im having this same problem, so please if someone knows the answer, please tell us.

    Ok, I solved the problem on my own blog by reposting all my own comments, then editing the timestamp to match the original comment, and then deleted the original.

    This worked for me since I didn’t have that many comments to edit, but for someone with a lot of comments, of course this is not a good solution.

    I think I won’t mark this one as solved because of that matter, and hope that someone can come with a better and less time consuming solution to the problem!

    ALSO looking for a solution to this.

    Josh Byers


    I guess we are still looking for a solution for this issue. My blog has hundreds of comments and it wouldn’t be practical to go in and edit them individually.

    I just imported from a WordPress xml file to another WordPress install (both are versions 2.8.5) and everything was brought over except the user_id for comments.

    I understand the issue with mapping each user’s comments if there is no user account but attributing a user_id to the post author doesn’t seem like it should be an issue.

    Looking for some moderator help.


Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Problem with comment user_id after import!’ is closed to new replies.