Keyword

Open Graph: Image

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 5 months ago #63072 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: Open Graph: Image
Yes, all the properties are generated dynamically. The size will not work right away because Facebook caches your URLs on its end.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
11 years 4 months ago - 11 years 4 months ago #63073 by flavio
Replied by flavio on topic Re: Open Graph: Image
Krikor,
I still have problem with Thumbnail of item on facebook with k2.

My version is recent 2.6.6, but i don't know how can I configure this settings.
I use also the plugin Phoca Open Graph Plugin


Many links posted on Facebook are shown wrong, got other posts. :silly:

Tks

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 4 months ago #63074 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: Open Graph: Image
Hello Flavio,

You can specify the image you want to show (must be at least 200px in both dimensions) in the component's params.

As for the Phoca Open Graph Plugin I am not sure you need this for K2 and I cannot tell you it will not create conflicts as well.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • scene66
  • scene66's Avatar Topic Author
  • Offline
  • New Member
More
10 years 11 months ago #63075 by scene66
Replied by scene66 on topic Re: Open Graph: Image

Andrii Natalukha wrote:

<?php
        $fbog =& JFactory::getDocument();
        $opengraph_meta = '
        <meta property="og:title" content="'.$this->item->title.'"/>
        <meta property="og:type" content="blog"/>
        <meta property="og:url" content="'.JURI::getInstance()->toString().'"/>
        <meta property="og:site_name" content="YOUR_SITE_NAME"/>
        <meta property="fb:admins" content="INSERT_YOUR_FACEBOOK_ID"/>
        ';
        if (!empty($this->item->image)) {
            $opengraph_meta .= '<meta property="og:image" content="'.JURI::base().''.$this->item->image.'"/>';
        }
        else {
            $opengraph_meta .= '<meta property="og:image" content="http://imagedoomain.com/no-image.jpg"/>';
        }
        $fbog->addCustomTag( $opengraph_meta );
?>

Thank you — I did not see your answer until now!

Please Log in or Create an account to join the conversation.

More
10 years 7 months ago - 10 years 7 months ago #63076 by YannisDr
Replied by YannisDr on topic Re: Open Graph: Image
@Krikor Boghossian I tried this with an implemented image less than 200x200px but it partially works.

I can't understand what the heck the "Image size to use when posting K2 items on Facebook" dropdown selection is for! There is absolutely NO change when touching this.

And IMHO, I think it is stupid to have a 200x200px picture when user opens an item just to make it possible to fit in a FB post. I don't get why can't it be possible to have a nice flat wide image picture instead?

Edit: the only difference I see when i touch the "image size to use when posting k2 items on FB" is when I see the source of the page: og:image's value is M, L, XL or whatever I choose.

Please Log in or Create an account to join the conversation.

More
10 years 7 months ago #63077 by YannisDr
Replied by YannisDr on topic Re: Open Graph: Image
I fixed my problem somehow. I used Facebook debugger (Facebook Url Debugger / Linter Tool) to clear Facebook's cache.
More:
stackoverflow.com/questions/1138460/how-does-facebook-sharer-select-images
developers.facebook.com/tools/debug

However, in Facebook debugger tool I can see that K2 needs to fix some important aspects, such as the warning about: "Admins And App ID Missing" or this: "og:image should be larger" while I have chosen the XL size from the parameters.

Please Log in or Create an account to join the conversation.

More
10 years 7 months ago #63078 by Marcel Beck
Replied by Marcel Beck on topic Re: Open Graph: Image

darkslayer wrote: Where do i need to put that code so facebook gets the image from my k2 article? is it in item.php?


Where exactly???

Please Log in or Create an account to join the conversation.

More
10 years 7 months ago #63079 by Lefteris
Replied by Lefteris on topic Re: Open Graph: Image
@Marcel Beck

You do not need to type any code. Just ensure that you are using K2 2.6.8. Then go to K2 parameters and select the desired image size for Facebook.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

More
10 years 5 months ago #63080 by Marcel Beck
Replied by Marcel Beck on topic Re: Open Graph: Image

Lefteris Kavadas wrote: @Marcel Beck

You do not need to type any code. Just ensure that you are using K2 2.6.8. Then go to K2 parameters and select the desired image size for Facebook.


I've tried everything, updating code, back to stock code, updating to K2 2.6.8 and it is still the same when I post on Facebook. Then I adjusted the sizes of the image parameters as well to fit the requirements still nothing, the debug too doesn't even scrape my site....


What are my options?

Please Log in or Create an account to join the conversation.

More
10 years 5 months ago #63081 by Lefteris
Replied by Lefteris on topic Re: Open Graph: Image
Do you see the image meta tag in the page source ? If the Facebook debugger is not fetching your site at all then this has nothing to do with K2 image size. If you have GZIP enabled, try to disable it as there are user reports that Facebook cannot fetch pages with GZIP. Also ensure that your page does not include invalid HTML markup.

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum