tabalinas / jssocials

Social Network Sharing jQuery Plugin

Home Page:http://js-socials.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Shares counter not working

qcharlotteq opened this issue · comments

All our shares counters are showing as zero. Can you please let me know how to fix?
Thanks

I am having the same is as @qcharlotteq. The only counter working is the facebook counter. Below is my code.


  // Extract index from the slide selected
  function extractSlideIndex(slide) {
    var selectedSlide = slide.toString();
    
    $.getJSON( photoAPIUrl , function( data ) {
      var gallery = data.acf.event_gallery_field;  

      // determine the starting index
      $.each(gallery, function(index, value) {
        if(value.photo.title === selectedSlide) {
          loadSocialShareBtns(value.photo.url);
          $(".ScrollContainer").slick("slickGoTo", parseInt(index));
        }   
      });
    });
  }

 // Social share buttons
  function loadSocialShareBtns(link) {
    $(".ShareContainer").jsSocials({
      url: link,
      showLabel: false,
      showCount: "inside",
      shareIn: "popup",
      shares: ["email", "twitter", "facebook", "linkedin"]
    });
  }