WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I import/convert hits from the plugin top 10 to wordpress popular posts plugin?

share|improve this question

closed as not a real question by Wyck, Brian Fegter, kaiser, Chris_O, toscho Sep 28 '12 at 21:55

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

up vote 2 down vote accepted

Short Answer

You don't.

Long Answer

These two plugins are fundamentally different. Popular Posts stores views in a custom field with each post. Top 10 creates a new table in the database and stores views there.

So you'll need to look for the wp_top-ten table in your database. It should have these fields:

  • postnumber
  • cntaccess

postnumber is the ID of your post and cntaccess is the number of views it has. You can move this into the pvc_views custom field for the post to migrate the data.

You'll likely need to script this in SQL; that's an exercise I leave to you. In reality, you'd be better served just switching to the new plugin and starting your counter from scratch.

share|improve this answer
ok, thnx a lot :) – Alex Feb 27 '12 at 20:04

Not the answer you're looking for? Browse other questions tagged or ask your own question.