Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Hector Cabrera

    (@hcabrera)

    Hi @trudslev,

    Absolutely. Both Top 10 and WPP store views count in a similar way so importing data from one plugin to the other is possible.

    Assuming you’re using the latest version of both plugins, try this:

    1. Go to Plugins and disable both Top 10 and WordPress Popular Posts.
    2. Log in into your hosting’s control panel and open PHPMyAdmin (or whatever your hosting offers to manage database tables).
    3. Select your site’s database, then empty WPP’s tables if there’s any data on them (wp_popularpostsdata and wp_popularpostssummary).
    4. Run these queries to import the total views data from Top 10:
      INSERT INTO wp_popularpostsdata (postid, day, last_viewed, pageviews)
      SELECT postnumber, NOW(), NOW(), cntaccess FROM wp_top_ten;
      
      INSERT INTO wp_popularpostssummary (postid, pageviews, view_date, view_datetime)
      SELECT postnumber, cntaccess, dp_date, dp_date FROM wp_top_ten_daily;

      Remember to change the wp_ prefix with the one your site uses.

    5. Finally, go back to your admin dashboard and reactivate WordPress Popular Posts.
    Thread Starter trudslev

    (@trudslev)

    Thank you so much.

    It went without a hitch. I did empty the tables first, since I had had WP Recent Posts turned on.

    Plugin Author Hector Cabrera

    (@hcabrera)

    Awesome! Thanks for reporting back, Sune. I’m sure this info will help other users as well.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Import from Top 10’ is closed to new replies.