Home Forums WTI Like Post PRO Number of votes

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #309
    RayJay
    Participant

    Please help me display number of votes. Is there a hook for this?

    Or standard query, define, then display with a <?php blah-blah?>

    Sorry, up late several days now trying to figure this out.

    Cheers,

    A

    #314
    Webtechideas
    Keymaster

    The functions are GetWtiLikeCount($post_id), GetWtiUnlikeCount($post_id), GetWtiTotalCount($post_id) to get the like, unlike and total counts respectively.

    #318
    RayJay
    Participant

    Than you! is this how I implement?

    <div id="votesbox"><?php GetWtiLikeCount($post_id)?></div></div>

    a

    • This reply was modified 8 years, 11 months ago by RayJay.
    #321
    RayJay
    Participant

    That last post may not have made sense…

    What do I wrap that “GetWtiLikeCount($post_id)” custom hook in? Do I have to mention it before the loop first… sorry for my noobiness.

    a

    #322
    RayJay
    Participant

    I used <?php echo GetWtiLikeCount($post_id)?> inside the div that will house the number of votes in my styled list…

    But it just shows a ‘0’… although there are votes.

    Any thoughts?

    Thank you!

    a

    #323
    RayJay
    Participant

    GOT IT WORKING… used this instead: <?php echo GetWtiLikeCount($post->ID);?>

    Thank you!!! now onto get that vote button working. 🙂

    Cheers,

    a

    #353
    paviod
    Participant

    Can you explain how you got this working? I’m trying to do something similar and it’s showing only 0 as a result

    #355
    Webtechideas
    Keymaster

    The above function GetWtiLikeCount is already available with the plugin. You need to pass the proper variable in place of $post->ID as per your code. Please make sure there are like counts for the post you are checking with.

    #359
    paviod
    Participant

    I’m trying to use <?php echo GetWtiTotalCount($post->ID);?> but it’s outputting 0 even when there are votes. Can you please past in the code needed to showcase total count as a function and be able to output that as a shortcode? This is why I bought the pro version but didn’t think I would have to program that myself.

    #363
    Webtechideas
    Keymaster

    You can see other users mentioning that it is working for them so there is no reason for this not to work for you. What is the like and unlike count for the post where its showing total as 0? You can share your site url for us to check. You can also send us the file where you are implementing the same. If you are using any theme, then send that as well with your code. We will look into that and suggest.

Viewing 10 posts - 1 through 10 (of 10 total)
  • The forum ‘WTI Like Post PRO’ is closed to new topics and replies.