Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter Doug M

    (@nes-native-english-services)

    Plugin Author Michael Ott

    (@mikeyott)

    It looks like you’ve got some conflicts happening. View the source and you’ll see four different instances where the Open Graph protocol is being output in the head (with conflicting content too), likely by four different plugins.

    Looking at this page for example… http://unglove.me/shop/fingerwraps-pool-glove/

    …view the source and search for Open Graph and you’ll see (at line 57, then line 204, 228 and 326). I suspect that Facebook is getting confused and resorting to pulling in the first image it finds instead, which happens to be http://unglove.me/wp-content/uploads/2013/11/billiard-balls.jpg (Facebook will resort to this action when it doesn’t find Open Graph tags or if the Open Graph tags are broken in some way).

    You’ll need to find out which plugins are outputting the Open Graph tags and see if there is an option to disable or modify them in some way. Ideally you only want a single set of Open Graph tags being output in the head on any given page. This may even involve disabling my plugin.

    As for Woocommerce support for my plugin, it doesn’t officially support Woo and I’m not entirely sure how it behaves with it, but that being said I might look into it.

    I hope that helps.

    Thread Starter Doug M

    (@nes-native-english-services)

    Thanks Mike for the detailed information and taking the time.

    I just did a quick video on my plugins and a conflict with Yoast. Not sure I understand what’s happening here.

    Vid is under 3min.
    http://screencast-o-matic.com/watch/cIlIQxnVOp

    Thanks again for such a quick resply.
    Doug

    Plugin Author Michael Ott

    (@mikeyott)

    Hi Doug,

    Thanks for taking the time to do the screen-cast – if only everyone seeking help could be so helpful!

    Yes that’s unusual. The only thing that comes to mind is my plugin and Yoast have some sort of conflict, though I can’t think of what. A function with the same name would throw an error upon plugin activation so it’s unlikely to be that because you would have seen it immediately.

    Could you try something? Just to take your theme of the equation: activate the twenty thirteen theme (or the new twenty fourteen if you updated to WP 3.8 today!) and see if the problem still exists. Conflicts are easier to diagnose if we can take the theme out of the equation. If everything works as expected using one of the standard WP themes then we know your theme has the issue, and we can work from there.

    If that proves to be no help (that is the problem still exists) let me know here and I’ll install the same plugins you have on a fresh WP deployment and and see if I can see anything obvious.

    Thread Starter Doug M

    (@nes-native-english-services)

    Mike,

    Thanks for the response and sorry for not having the time to follow up sooner on this.

    I made another video of me running through some things. It’s a bit long but the first 4 min is probably what you’re after. The last 4 minutes is me discovering that it’s a single product related issue. The other products pull the correct information without needing your plugin.

    In the first 4 minutes it’ll basically show you that when I activate your plugin it adds the code twice to the page.

    Hope it helps and maybe you’ve got some ideas on why it would only act this way on the one product I want to push hard… Makes no sense to me.

    Doug

    Plugin Author Michael Ott

    (@mikeyott)

    Thanks Doug,

    Yes it’s an unusual one. I have no idea why it was being output twice like that – because my plugin is strictly instructed to only output once in wp_head(). There’s a conflict which would be too difficult for me to attempt to resolve without me having an exact working copy of your site on my local development server, and then manually examining what some of the other plugins do. That aside, I think that’s probably outside the level of support I’d offer for Facebook Thumbnail Fixer anyway.

    But if you’d like to try a manual solution instead, add the open graph tags manually into your header.php file with a couple of conditions. Just make sure you deactivate my plugin and any others that output open graph tags.

    Add this inside the <head> of header.php


    <?php if ( is_home() ) { // If on the homepage ?>
    <!--/ Open Graph for Homepage /-->
    <meta property="og:title" content="<?php echo get_bloginfo(strip_tags('name')) ?>" />
    <meta property="og:type" content="website" />
    <meta property="og:url" content="<?php echo home_url() ?>" />
    <meta property="og:description" content="<?php echo get_bloginfo (strip_tags('description')) ?>" />
    <meta property="og:site_name" content="<?php echo get_bloginfo(strip_tags('name')) ?>" />
    <meta property="og:image" content="http://unglove.me/path-to-thumbnail-image.jpg" />
    <?php } ?>
    <?php if ( is_woocommerce() ) { // If on a woocommerce page ?>
    <!--/ Open Graph for Woo Product /-->
    <meta property="og:title" content="<?php echo get_the_title() ?>" />
    <meta property="og:type" content="product" />
    <meta property="og:url" content="<?php echo get_permalink() ?>" />
    <meta property="og:description" content="<?php echo get_the_excerpt() ?>" />
    <meta property="og:site_name" content="<?php echo get_bloginfo(strip_tags('name')) ?>" />
    <meta property="og:image" content="<?php $featuredimg = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), "Full"); echo $featuredimg[0]; ?>" />
    <?php } ?>

    My preliminary testing shows this to work with Woo Commerce. I’d be interested to know if this works for you too.

    Plugin Author Michael Ott

    (@mikeyott)

    I trust you got yourself sorted?

    Thread Starter Doug M

    (@nes-native-english-services)

    Hi Mike, I really appreciate the follow up.
    I wish I could say yes but I simply haven’t had time to go through this and work it out. I’ll try to get to it this week.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Woocommerce?’ is closed to new replies.