1

I'm creating a plugin which counts social scores on various sites. It uses the various API's available on the web to determine a "count" of shares or likes across facebook, twitter, delicious, linkedin, stumbleupon, digg etc.

Many of you are probably familiar with javascript widgets for these sites. I'm frustrated with the overhead which this brings (multiple javascript calls, so I'm building something to work this out and store natively within Wordpress). This will also give scope for designers creating their own buttons with HTML, and a shortcode will show the share count.

My problem lies in the speed of the response for the networks. They can be slow, so I'm looking for architecture / design advice. I was thinking of creating a table which holds POST_ID and a collection of scores which is updated often via WP-CRON.. and updates when a user clicks the share button as well to keep it in synch. Sound like a valid idea? Or any other ideas?

If you are still confused, take a look at the new share button on the BBC. I want to bring this to Wordpress, minus the speed overhead.

2
  • 1
    Hi, are you still on this subject. The last few weeks I have developed a set pf plugins that get's all the data from the different sites. I have implemented the system in such a way that it works completely asynchronous with the website, meaning that it will not cause any delays. Furthermore is there no cron used, and no curl etc, all build in wordpress fucntions. If you want to collaborate on this please let me know. Commented Nov 17, 2011 at 2:49
  • Saif, I have been working at it recently. For Facebook initially.. Would love to collab on it. Ping me a DM.
    – Squiggs.
    Commented Nov 21, 2011 at 13:51

1 Answer 1

2

WP_Cron & 'save_post'/'update_post' hooks sound good. But I'd try saving it either inside an option field or as post_meta data. A stand alone table might be too much an no one wants extra tables. Furthermore you leave other possibilites open if you go the "native" root with post_meta.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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