Facebook Like Counter is not showing in your Counter

Posted in: Newspaper
Post count: 45

Hi,

I am using your theme but just noticed it has stooped showing like counter for facebook. It was working good after installation and when and how it stopped I am unsure and right now it is showing 0.

My Website is: http://banglalive.com/
My Facebook Fan Page is: https://www.facebook.com/banglaliveofficial

Let me know the solution.

Thanks

Post count: 22421

Hello,
This is a known issue. Facebook recently updated their website and changed the code the social counter picked up. The problem is on our list and we will adjust our counter to the new facebook version as soon as possible.
Thank you!

Post count: 45

Kindly update when you have any solution.

Post count: 22421

Hi,
The problem was fixed and an update released. Please update your theme to the latest version 6.6 and also update your social counter by deleting the current version and installing the one that comes with the new theme version.
Thank you!

Post count: 89

Hi

I can’t upgrade to the latest theme as I would have to create too many new custom sidebars (40-50).
Will the new social counter work with Newspaper Version: 444 ?

Post count: 22421

Hello,
Unfortunately we have not tested the new version of the social counter with the old version of our theme. You can try to download and install it (download the new version of the theme from envato and just update the plugin), but as the code was changed quite a bit since version 4, i do not think it will work.
We suggest you update your theme to the latest version.
Thank you!

Post count: 89

Thanks Bogdan

I want to upgrade to v.6 – is there a way I can preserve the existing widgets and sidebars (about 5 widgets each different in around 40 sidebars) or at least reduce the workload?

Post count: 73

Hello Bogdan – hello Team 🙂

I have updated the theme to the newest version. Also I made the update for the social counter plugin. But the Facebook likes are still not shown on http://www.1-2-family.de

Best regards
Torsten

Post count: 22421

Hello,
Unfortunately the theme was changed quite a bit since version 4 and some elements will not work anymore. The sidebars should not be affected by this update, only widgets inside them that could not work anymore. (the social widgets from version 4 are no longer present in version 6)
Always make a back-up before updating so you can revert to the previous version if needeed. Please follow this tutorial on how to update your theme :https://forum.tagdiv.com/how-to-update-the-theme-2/
Thank you!

Post count: 73

Hi Bogdan,

I must admit, that my upgrade to version 6+ is a while ago. The Facebook counter worked until a few days ago. I did not change any line of code since then. So i don’t think, that this has got something to do with the update.

I wrote this, because I was happy to see, that there was an update of the theme (a few days ago – or yesterday?). So i of course updated theme and plugins right away – in hope, that the facebook counter will work again.

But even after this update – i does not. So i have replaced all old social counter widgets with a new one. But no result …

Post count: 22421

Hello,
Unfortunately the new social counter is not working for everyone due to facebook changes so we decided to recreate it from the bottom up. We are working hard on it and a new update to the plugin will be out ASAP.
Thank you for your understanding.

Post count: 45

Just got a temporary FIX, may help someone:

I made changes in this file:

plugins/td-social-counter
Line: 213

Replaced these lines of code:


$td_data = $this->get_url("http://facebook.com/$user_id");

if ($td_data === false) {
$this->log(__FUNCTION__, 'The get_url method FAILED, returning 0');
$buffy_array = 0;
break;
}

$pattern = "/id=\"PagesLikesCountDOMID\">(.*?)<\/span><\/span>/i";

//first match - get the string with number of likes and the likes word
preg_match_all($pattern, $td_data, $matches);

//replace all the classes in the sting returned by first regular expression

$sub_string = preg_replace('/class=\"(.*?)\"/i', '', $matches[1][0]);

//extract only the numbers
$buffy_array = $this->extract_numbers_from_string($sub_string);

With the below:


/* ---------------------------------------------------

----- CUSTOM SCRIPT WRITTEN BY -------
----- SANNY SRIVASTAVA -------

--------------------------------------------------- * /
$fb_page_detail_xml = "http://api.facebook.com/restserver.php?method=links.getStats&urls=https://www.facebook.com/$user_id";
// read feed into SimpleXML object
$fb_page_detail_xml_array = simplexml_load_file($fb_page_detail_xml);
$buffy_array = (int)$fb_page_detail_xml_array->link_stat->like_count;

Thanks

Viewing 12 posts - 1 through 12 (of 12 total)
The forum ‘Newspaper’ is closed to new topics and replies.