• Hi!
    At first thanks for a great plugin!

    Please help me to find solution.

    I open posts in popup using Ajax.
    All post data I get by post ID
    I mean:

    $ajax_post = get_post( $_POST['post_id'] );

    then I get title, thumb and content such way:

    $ajax_post->post_title
    $ajax_post->post_content
    get_the_post_thumbnail( $ajax_post->ID , 'full' )

    than I use shortcode:

    [Sassy_Social_Share url="'. get_permalink( $ajax_post->ID ) .'" title="'. $ajax_post->post_title .'" count=1]

    All working, but share counters does not show… (PS: with single.php all working fine )

    Maybe I should set one more parameter or smth else?

    e.g. for facebook counter I have

    <ss class="heateor_sss_square_count heateor_sss_facebook_count">&nbsp;</ss>

Viewing 15 replies - 1 through 15 (of 16 total)
  • Plugin Author Heateor Support

    (@heateor)

    Hi,

    Thanks for the appreciation ??
    We need to see the popup at your website. Let us know your website url.

    Thread Starter webkupas

    (@webkupas)

    Hi =)

    here please:
    https://www.hygienics.ch/en/news/

    click on any news

    Plugin Author Heateor Support

    (@heateor)

    When popup appears, you need to call following Javascript function:

    <script type="text/javascript">
    heateorSssCallAjax(function() {
        heateorSssGetSharingCounts(1, 0);
    });
    </script>

    Thread Starter webkupas

    (@webkupas)

    Great!!!

    It works =)

    Tanks for your support!

    All the Best! =)

    Plugin Author Heateor Support

    (@heateor)

    You’re welcome ??

    Thread Starter webkupas

    (@webkupas)

    Hi again =)

    Sorry, there is another problems…

    Counter loads only when I open popup at first time, another ones counters aren’t shown, untill I reload page. Maybe I should reset or reload plugin on popup close? If so please tell me how can I do this.
    e.g. please open post “Hygienics.ch at the igeho” on this page https://www.hygienics.ch/en/news/
    Open it one time (U could see counter(2) with facebook icon) and then second time (couters are not shown).

    And I noticed that Twitter counter is not working. How can I solve this issue?

    Kind Regards,
    Pavel

    Plugin Author Heateor Support

    (@heateor)

    Hi Pavel,

    This seems related to the timing when you are calling the Javascript code. You have to call that code

    <script type="text/javascript">
    heateorSssCallAjax(function() {
        heateorSssGetSharingCounts(1, 0);
    });
    </script>

    on click event of post title (i.e. when popup appears).
    Twitter counts depend on the third party service you are using (opensharecount or newsharecounts). Did you register your website at their website? You can see detailed help below Show share counts option at sharing options page in admin area.

    Thread Starter webkupas

    (@webkupas)

    Hi,

    Thanks for your advices, but it not helps me.

    Yes I fire code U provide me above on click event after content loaded via ajax. I see counters after first loading but do not after next loading. I can see counters again only after page reload.

    I’ve register at the both services but twitter counter still not working (I used radio switcher at options page).
    for example here is single page (not popupped)
    https://www.hygienics.ch/en/first-news/
    and there is no twitter counter

    Thanks,
    Pavel

    Plugin Author Heateor Support

    (@heateor)

    Yes I fire code U provide me above on click event after content loaded via ajax. I see counters after first loading but do not after next loading. I can see counters again only after page reload.

    Would you drop an email at support[at]heateor[dot]com regarding this so that we can help you out?

    I’ve register at the both services but twitter counter still not working (I used radio switcher at options page).

    Then it is something related to their API. Would you try asking their support?

    Thread Starter webkupas

    (@webkupas)

    OK,
    Thanks for your answers

    Thread Starter webkupas

    (@webkupas)

    So I want to note that twitter counter does not work on their page (third part service). U can try here
    https://newsharecounts.com/twitter-share-counts-in-sassy-social-share-for-wordpress/

    Plugin Author Heateor Support

    (@heateor)

    So I want to note that twitter counter does not work on their page (third part service). U can try here

    We don’t know what service they are using to fetch Twitter counts at their website.
    Did you try contacting their support as per on the page you have mentioned – “If you have any trouble, tweet us or send us a message by clicking support button on the left.”

    Thread Starter webkupas

    (@webkupas)

    I meant in previous post that this is not Sassy Social Share Plugin’s issue.
    This is issue (I think so, but not sure) getting from 3rd party providers.

    Yes I’ve open ticket at the newsharecounts.com, and will return to U with feedback if have some news.

    Plugin Author Heateor Support

    (@heateor)

    Okay, great.

    Thread Starter webkupas

    (@webkupas)

    Hi, Im back =)

    Support of Newsharecounts.com help me in my question, and I think this information may helps U in future customers requests.

    Here is their answer:

    Hi Pavel,
    
    Our service uses Twitter search to discover tweets.
    
    Twitter search may omit certain tweets, especially tweets from accounts with very few followers (treating them as low-quality). That is why we do not see your tweets. 
    
    Here is a search for your page. As you can see, only my tweet is present.
    https://twitter.com/search?q=http%3A%2F%2Fwww.hygienics.ch%2Fen%2Fnews%2F%3Fnews%3D1310&src=typd
    
    This is not a problem in general, as normally accounts with very few followers almost never share anything, aside from testing cases like ours.

    So this explains why counter wasn’t increase after I shared post and why it increased after Newsharecounts.com support share last one.

    Hope this information will save some time for other developers, because I struggled with this issue during 2 days =)

    And thanks a lot for Team Heateor’s and Newsharecounts’s support!

    Problem solved.

    All the best,
    Pavel

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘How to get share counters if have post ID?’ is closed to new replies.