WordPress.org

Ready to get started?Download WordPress

Forums

Facebook
[resolved] Like and Send buttons not working (7 posts)

  1. frons79
    Member
    Posted 1 year ago #

    Hi, here's the problem: I've switched to TWENTY-ELEVEN theme after some time. After some checks I realized the "Like" and "Send" buttons from this plugin weren't working anymore.

    They have always been set to be present in all posts, main index and single posts, on the top of the article. Now when I press the "Like" button, a cropped windows comes out in which I can see what I was expecting to see, only cut in less than half the width size.

    For the "Send" button it definitely gets trickier since it gives me only a full white window only...

    I've already tried to flush the plugin out, refresh the cache and install it back, but it didn't work at all.

    I have only this plugin that has anything to do with OGP, and its settings are correct (because before it was working)...

    Every suggestion is highly welcomed, thanks.

    My website is http://www.obscura.ws

    http://wordpress.org/extend/plugins/facebook/

  2. WeePee
    Member
    Posted 1 year ago #

    Hi!

    I've got the same problem. It took me many hours of debugging but (with the help of a friend) I found the cause within the style.css:

    /*      Make sure embeds and iframes fit their containers
            ----------------- */
    embed,
    iframe,
    object {
     max-width: 100%;
     width: 100%;
    }

    So, the max. width of the iframe is limited to the width of the container (in this case, the FB button). I don't know if there is a sane reason for doing this (most themes don't) but if you remove the "max-width" line it should work correctly! At least it does for me...

  3. WeePee
    Member
    Posted 1 year ago #

    In case you're interested: I chose a less "invasive" solution and only disabled this "feature" for iframes:

    embed,
    object {
      max-width: 100%;
      width: 100%;
    }

    Just in case there's a good reason to limit the width of embeds ;)

  4. frons79
    Member
    Posted 1 year ago #

    Thanks for your reply: I tried both the solutions, but none of them gave me back any result :(

  5. WeePee
    Member
    Posted 1 year ago #

    I checked your site and it seems that the CSS code is not overwritten in your child-theme. If I make the changes within the original style.css (with Firebug) your like button works correctly!

    I don't know what's the problem with your child theme (tell me if you find out). I made a copy of the original theme and maintain it myself. Partly because I modified PHP code but also because that child-theme thing never worked correctly for me either...

  6. frons79
    Member
    Posted 1 year ago #

    I overwrote it directly on the parent theme and now it works, but yet I don't understand why it wasn't working before.

    Now I have another issue: since I'm using also the Contextual Related Posts plugin (http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/) which places thumbnails of related articles at the bottom of my own, when I hit Like/Send button, Facebook plugin does not grab the right thumbnail for the link to be sent, but it chooses randomly between one of the five (the one of the main articles plus the four of the linked articles).

    Any idea on how fixing this annoying issue as well?

  7. Niall Kennedy
    Member
    Plugin Author

    Posted 1 year ago #

    The Facebook plugin will explicitly define your webpage preview image if a post thumbnail is present.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic