Open Graph Pro

Open Graph Pro is a WordPress plugin.

It adds Open Graph Protocol metadata to your WordPress powered blog/website. It does not (yet) add any Facebook “Like” buttons.

The Open Graph Protocol enables your website/blog to have the same functionality as a Facebook page.

Open Graph Pro is hosted on wordpress.org:

Upcoming versions

Version 1.1 will feature an API for theme and plugin developers to access the Open Graph Protocol metadata to add “Like” buttons to their blogs and to use custom Object Types. Go to the download page and grab the Development Version if you want to try it!

  1. is there something particular to paste in to get the permalink to the post to show up when using the like button? How to go about entering embed info when creating my button at: http://developers.facebook.com/docs/reference/plugins/like/

  2. Hi Chris, I’ll release an update of this plugin shortly with the Like button built in… Meanwhile if you’re putting this into your theme: you need the get_permalink() function. But that does not give you the correct link to like when you use the “Use metadata of the following page” feature of my plugin; for that you’ll need to wait for the next update or “steal” code from the wp_head() function in the plugin.

  3. Hi there!

    I just installed the plugin and Facebook still isn’t recognizing the site image for the thumbnail.

    I added the replacement image in the settings, and that still didn’t work.

    Any ideas?

  4. Hi Louis,

    What site are you using the plugin for? The site linked to in your comment either does not run the plugin (have you activated it after installation?), or your theme is not using the wp_head() hook.

  5. Hi there,
    is there any way to make the plugin produce valid XHTML? I heard that I can paste a snippet with a facebook agent but I dont know where exactly… do you have any solutions for this problem?

    thanks in advance!

  6. I have video content on a blog and was hoping that your plugin would add OG metadata allowing the video to play inline in Facebook or at least to grab a thumbnail of the video. Any ways round this?

  7. Hi Jonathan,

    The biggest issue I face with inline video or audio is that it requires the actual video or audio file URL. Most users just embed Youtube/Vimeo/etc. players into their posts, but I haven’t figured out a good way to extract the media URL from that.

    I would still like to add this as a feature. So if you have any ideas or insights you could share: please do!

  8. Hi Birgit,

    Strictly speaking Open Graph Protocol metadata is not (X)HTML but RDFa.

    So to pass the W3C Markup Validation Service you need to change your site’s doctype declaration. You will probably find this in your theme’s header.php file. Here’s a page describing what you need to do: http://rdfa.info/wiki/How-to-validate

    Please note that there are still different doctypes for XHTML Transitional, (Strict) XHTML, etc. (even for HTML 4) in combination with RDFa.

    Unfortunately there’s no way to have the plugin change this automagically as there is no filter for the doctype declaration. It’s hardcoded in all themes I know, including all “official” themes.

  9. Hi Martin,
    I arrived here from the plugin WP-AutoSocial (http://wordpress.org/extend/plugins/wp-autosocial/), because the images that I post don’t thumbnail on Facebook. The author suggested me to install your plugin (http://wordpress.org/extend/plugins/ogp/). I just installed the plugin and Facebook still isn’t recognizing the site image for the thumbnail.

    I’m using a theme from http://www.press75.com.
    It uses the following code to show thumbnails in posts:

    <img src="ID); ?>" alt="" />

    How can I solve/integrate it to show thumbs correctly on my fb page
    (http://www.facebook.com/pages/StreamSpaceme/330284483662901?sk=wall)?

    Thanks a lot!

  10. Hi Martin,

    I believe something must have recently changed with Facebook because when posting before I was getting my featured image and title and description. I was using FetenWeb image_src Metatag. I installed yours as recommended by NicktheGeek from StudioPress, but I’m still having the same issue.

    If you look at my most recent post you will see the OG code is all there.

    Do you know what might be causing this?

  11. Hi Chad,

    You appear to be using a custom URL for the image. It’s www.30isthenew20.com/headshot.jpg but Facebook rejects that because it doesn’t start with either http:// or https:// – you should just prepend http:// and it’ll show.

  12. Thank you and sorry for that oversight on my part. I’m always wondering if it can pull the description from my post instead of what appears to be a certain number of characters.

    For example in my most recent post, if I post that URL to FB the description reads “Snowboarding is by far one of my biggest passions and when my trip to Big Sky, Montana fell through I had to scramble to make something happen. Thankfully the Internet exists and we have these things called Facebook and Twitter. Back in 2007 I met Esp…”

    But my meta description which FB would use before this plugin is “There are a lot of resorts in the United States, but none offer a better value than the Epic Local Pass to Colorado.”

    Is there a way to control this so I don’t get the random unfinished sentence with the …?

    Thanks.

  13. Hi there,

    I’m using your plugin but it seems to be still pulling the images from my page, instead of using the custom image I assigned (http://knitfreedom.com/wp-content/uploads/2012/02/KF-Icon-transparent-backround.png).

    Is there something I’m doing wrong? I checked the box to use header images only – it’s still pulling up an image from my footer.

    Thank you!

  14. I have install this plugin working fine when someone like post/page. But it has one problem that is it doesn’t show website name.

    For Example:

    abc likes xyz.

    but not as

    abc likes xyz on example.com

    possible fix ?

  15. Hi Martin, do you know how to exclude shortcodes from the og:description? I use shortcodes for ads, and when I post to facebook the [shortcode ad example] appears. Thx

  16. Hey Martin,

    ogp either doesn’t play along with WP multisite install, or with Jetpack. Anyway, whatever the cause, it simply doesn’t show up. – Let me know and I’ll provide debug info / turn ogp back on / etc.

    - Nils

  17. Well – nevermind – looks like I had a knot in my brain. Thanks for looking into it so quickly though!

Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>