Wrong featured image (12 posts)

  1. Rafael Fischmann
    Posted 3 years ago #

    The OpenGraph metadata for the plugin doesn't define images inserted inside the post. Because of that, it's picking up the first image from my featured posts on the top of my site, and not an image related to the post. OpenGraph should list links for images inside each post.

    You can check it out at http://macmagazine.com.br



  2. romaintb
    Posted 3 years ago #

    I am having the same issue.

    http://developers.facebook.com/tools/debug/og/object gives me the expected result, but when sharing a post, it shows the first image from related posts.

  3. Matt Kelly (Facebook)
    Plugin Contributor

    Posted 3 years ago #

    Thanks for the feedback, we'll take a look.

    Do you have steps that we can take to reproduce the issue we're seeing (posting an article, setting images, etc)?

  4. romaintb
    Posted 3 years ago #

    This error always happen (Raphael, do you concur ?), you can see it here : http://www.ykone.com/kenzo

    The opengraph tag has the correct image set, but when I click share, I see the first image from related posts, not the one set in the tag.

  5. Rafael Fischmann
    Posted 3 years ago #

    Correct, you just need to share any link from a site like ours, that has related/featured images on the top. Mine is working now because I'm not currently using this plugin.

  6. Mark
    Posted 3 years ago #

    FWIW, I've seen the same behavior with regards to Facebook ignoring og:image with likes/shares using the new plugin. I haven't done an exhaustive comparison, but sites that it's working on seem to still be using the (older?) open graph meta tag style in the header such as still documented here:

    <meta property="og:tag name" content="tag value"/>

    where the current plugin is using:

    <meta property="http://ogp.me/ns#locale" content="en_US" />

    When I run pages through the debugger, it shows that they have the image tag, but when I share them, it's hardly ever the image chosen.

  7. Rafael Fischmann
    Posted 3 years ago #

    I'm currently using this plugin:


    Here's an example:


    On the source code:

    <meta property="og:image" content="http://macmagazine.com.br/wp-content/uploads/2012/06/26-mbp01-600x350.jpg">

    That's how it should work.

  8. rorypw
    Posted 3 years ago #

    @Matt Kelly: I am having the same issue...

    When I share, like or comment on a post using the Facebook WordPress Plugin, the wrong image is used on my timeline.

    If you comment on this page, the wrong image will show up: http://shopwithmeaning.org/2012/07/better-world-books-changing-their-world-with-one-for-one-books/

  9. lorielue
    Posted 3 years ago #

    is there a fix for this??

  10. janmalagucute
    Posted 3 years ago #

    got the same problem.

    Waiting for fix

  11. pixeline
    Posted 3 years ago #

    Change line 138 of file wp-content/plugins/facebook/fb-open-graph.php
    $meta_tags['http://ogp.me/ns#image'] = array( $image );
    $meta_tags['og:image'] = array( $image );

    Solves the problem for me... beware of plugin updates, which will remove the fix.

  12. janmalagucute
    Posted 3 years ago #

    Thanks pixeline.

    It works for me

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Facebook
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic