Finds the number each of your posts have been shared on Facebook and saves it as a hidden meta field.
The numbers are updated each hour through a cron job.
The update is non-blocking so visitors won’t notice any performance degradation.
A widget for displaying most shared posts is included, and the output is easy to override.
I have only tested this on one site, but it works flawlessly for me. Please let me know if you have any issues. Fastest way to get a response is by Twitter: http://twitter.com/bjornjohansen
- I don’t like your markup. How do I provide my own?
Copy bj-fbpp-widget.tmpl.php to your theme folder and customize as you like. It’s a standard WP_Query Loop.
- How do I display the number of shares?
Look inside bj-fbpp-widget.tmpl.php (there’s sample code in a comment).
- Added missing screenshot
- The included widget now lets you select what post types to show
- Changed from the graph API to FQL
- The background updates now uses HTTP 1.1 so it works with shared hosting as well
- Tested up to: 3.4.2
- Tested up to: 3.4.1
- Screenshot descriptions in readme.txt had fallen out. Back in now.
- Added screenshots
- Removes output buffering from the update response to avoid timeouts
- Improved the fetch queue
- Added filter: bj_fb_num_posts – Number of posts to fetch per batch (hour). Defaults to -1 (all posts)
- Added filter: bj_fb_post_type – Post type (content type) to find shares for. Defaults to ‘all’
- Seems to work just fine