[Resolved] Facebook "Like" and "share" buttons

Home Forums Support [Resolved] Facebook "Like" and "share" buttons

Home Forums Support Facebook "Like" and "share" buttons

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #700467
    Ram

    Hi, I tried to include facebook “like” and “share” buttons on my blog posts using the hook “before_header”. But it’s not working.

    As per Facebook instructions, the code within the <scrpt>..</script> tags had to be pasted on every page, just after the <body> tag.

    I checked the page source code in the browser (for the posts), and I found that the required code (added through hook) is present in the body tag of html. but still the buttons are not appearing on the page.

    there is no problem with the facebook code. I tried that on another theme and it’s working fine with that theme.

    Please help.

    GeneratePress 2.1.4
    GP Premium 1.7.2
    #700468
    Ram

    just to add further… there is no problem with the facebook code. I tried that on another theme and it’s working fine with that theme.

    #700616
    David
    Staff
    Customer Support

    Hi there,

    The URL provided doesn’t like to a site built with GP?

    #700630
    Ram

    I had restored my previous version for a short while to check something, which is not using GP. My bad luck that you visited during this period. Please check now.

    https://krishva.com

    Thanks for your effort.

    #700668
    David
    Staff
    Customer Support

    so the script is in place but where are you outputing the HTML for the button?
    See here:

    https://developers.facebook.com/docs/plugins/like-button

    #700739
    Ram

    Thanks for all your help. this is resolved. I added another hook with the following code and it worked.
    <div
    class=”fb-like”
    data-share=”true”
    data-width=”300″
    data-show-faces=”true”>

    #700822
    David
    Staff
    Customer Support

    Glad i could be of help

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.