Import Wordpress Comments

plinanplinan Member
edited July 2012 in Questions
As discussed on this post: http://vanillaforums.com/blog/news/introducing-vanilla-comments/

Is there any update on importing existing comments into vanilla comments? I'd love some help migrating the current comments!

Comments

  • LincolnLincoln Staff
    edited July 2012
    Howdy @plinan, our suggestion for that situation is to write a condition in your comments.php template so that it uses WordPress comments for posts before the date you switched, and Vanilla comments after that date. It's a lot simpler than trying to migrate all previous comments.

    We do offer importing services, but it wouldn't be free since we don't have a standard exporter for WordPress comments yet.
  • Thanks for the reply @lincoln. I am not very technical when it comes to PHPs. Is there a guide on how to do what you just mentioned? Thanks!
  • LincolnLincoln Staff
    edited August 2012
    Well, I'd need to refer you to the WordPress help docs: https://codex.wordpress.org/Conditional_Tags (and generally the rest of that site).

    It could look something like this (where '1 august 2011' is replaced with the day you switched), probably in comments.php in your theme.
    <?php 

    if (date('U') > strtotime('1 august 2011')) {
    // Vanilla solution
    }
    else {
    // Old WordPress template
    }
  • Thanks @linkcoln, I'll give that a try.
This discussion has been closed.