Problems with Facebook OpenGraph and Wordpress - facebook

I installed some meta tags in my wordpress blog (header file), example:
<meta property="fb:app_id" content="340807095947367" />
<meta property="og:site_name" content="My Website" />
<meta property="og:description" content="Description HERE" />
<meta property="og:type" content="website" />
<meta property="og:image" content="http://www.mywebsite.com/img/tinypic.png" />
And this are working fine with all wordpress posts and pages but it fails with home (main page). Seems that Facebook can't find these meta tags in my home, but they are in source code.
I really don't know what is causing this error, so i can't fix it.

With the facebook open graph debugger the home URL seams to return 503 bad response most of the times, but occationlly 200 OK. If you want a handy way to "emulate" the Facebook fetch bot yourself and fiddle around check out Facebook isn't crawling my site
The warning about "Inferred Property" is because your home URL does not explicitly provide og:url and og:title tags. Add something like this to the home URL document:
<meta property="og:title" content="Porto de Mós Online - O Portal do seu Concelho" />
<meta property="og:url" content="http://www.portodemosonline.com/" />
Also the home URL seams to have some kind of broken BOM header (0x09 0xef 0xbb 0xbf) before the doctype that might confuse. 0x09 is tab so i would suspect that some PHP file is outputting this somehow, maybe a junk tab outside the <?php ?> tags.

To the point above, I wanted to add a little specificity. At the top of the tags in the header.php file, (wordpress) my template file ALSO had ?>. I removed the "!DOCTYPE" and all is indeed well.
I would hat for someone to use a plugin who doesn't need to and can still get all the benefits of the XFBML/HTML5 attributes this code can offer.
Thanks for staying with it and posting this. I know it's not a discussion, but there's a little detail in there. ;)

I would suggest that rather than adding custom open graph parameters, try to use this plugin:
http://wordpress.org/extend/plugins/wp-facebook-open-graph-protocol/
This plugin is well and works fine. I am using this for my blog.

Problems like this are the reason I wrote a plugin to handle it -- Complete Open Graph. I've tried other plugins past, and found them to make some strange assumptions about content I want to use for Open Graph, or just be waaaaaay too much code bloat for what I want to use it for. I think mine is the perfect balance of works-out-of-the-box, and yet flexible enough for developers to filter as they need. You should check it out!
https://wordpress.org/plugins/complete-open-graph/

Related

open graph meta tags not working in facebook

Okay, I can not figure this out for the life of me. I created a new site, and wanted to add the open graph meta tags like on my old site (which is working fine). When I added these to my new site and tested them in facebook debugger, it says that they are not present. I get this back when I test it:
Inferred Property The 'og:url' property should be explicitly provided, even if a value can be inferred from other tags.
Inferred Property The 'og:title' property should be explicitly provided, even if a value can be inferred from other tags.
Inferred Property The 'og:description' property should be explicitly provided, even if a value can be inferred from other tags.
Inferred Property The 'og:image' property should be explicitly provided, even if a value can be inferred from other tags.
Also, it is not finding the image even though it is there as well. Here is the code from my site as follows:
<meta property="fb:admins" content="100002683693547" />
<meta property="og:title" content="JDerry Art" />
<meta property="og:type" content="website" />
<meta property="og:url" content="http://www.jderry.com/2015" />
<meta property="og:image" content="http://www.jderry.com/2015/images/link.jpg" />
<meta property="og:description" content="Art and Illustration by J. Derry" />
<meta property="og:site_name" content="JDerry Art" />
my new site URL is: http://www.jderry.com/2015/
I have tried all suggestions for similar issues on here and other forums, as well as tried moving the order of the tags to no avail...
Any and all help will be greatly appreciated as this is starting to drive me nuts as there appears to be no definite answer and all suggested solutions yield the same problem. Thanks in advance.
P.S. My old site was xhtml and my new site is HTML5, not sure if that has any influence on this issue?
When you are using Open Graph Object Debugger . make sure you check the time last scraped and make sure its up to date with the changes on your website.
you can click on fetch new scrape information , to get the new data. and right now your open graph tags are working fine .
These are the raw tags that we found
Meta Tag <meta property="fb:admins" content="100002683693547" />
Meta Tag <meta property="og:title" content="JDerry Art" />
Meta Tag <meta property="og:type" content="website" />
Meta Tag <meta property="og:url" content="http://www.jderry.com/2015" />
Meta Tag <meta property="og:image" content="http://www.jderry.com/2015/images/link.jpg" />
Meta Tag <meta property="og:description" content="Art and Illustration by J. Derry" />
Meta Tag <meta property="og:site_name" content="JDerry Art" />
I was having the same problem, and what was causing it for me was that the content of og:url was just mywebsite.com, and not http://www.mywebsite.com.
The problem for me was that I had ipv6 enabled for my site and I didn't had a proper configuration in my web server settings.
HEY GUYS HERE'S MY ANSWER, i HOPE IT WORKS FOR YOU AS WELL: I try'ed every sugestion I can get my hands on, and what worked for me was this:
go to: https://developers.facebook.com/tools/debug/og/object/
Once you are there, paste the URL from the web page you wish to share in the box, and hit the button "retrieve information from the new extraction"
After you do this, it will appear some information, WHAT YOU ARE GOING TO NEED from this information, is the "og:update_time" element, on the right side of this element you will have a number, you are going to need to add this element along with this number to your meta information, someting like this:
meta property="og:updated_time" content="1496821331"
every number for every page is UNIQUE, but I find that if you put the same number in more than one web page it still works, but you may wanna put the specific number for each web page you are going to need (NOTE: in my experience,
you DONT need to have the image in the same directory as the meta is, actually, I use an image from google images and work out just fine!)
this is an example of the og:updated_time
I hope this can help you guys.
How I fixed this issue:
Turns out that the facebook scraper was timing out before it could get the content. You can check if this is happening to you with this tool. It will give a red error message if it is indeed timing out.
I'm making a wordpress site so I fixed this with the "Super Cache" plugin, which caches the content so that the facebook scraper can load it fast enough to not timeout. You still have to scrape multiple times (up to 4) with the sharing debugger for all the content to come through and work because the image loading is asynchronous.

Social network post links not working properly

The problem I'm having is when I post a link to a post on my website to either Facebook or Google+ that link points to my homepage. Even in preview, the thumbnail displayed is that of the homepage.
From what I have found (which hasn't been much) it seems that the problem might be with the facebook metadata. I have tried to validate it on facebook's open graph validator and at first I was getting a 206 result when the links were working. Now I get: Facebook URLs aren't scrapable by this Debugger. Try your own. Not sure why.
Having the same issue with Google+. When I first published the website it was working fine and this happened out of nowhere.
Here is what I have in my header:
<!--Facebook Metadata /-->
<meta property="og:title" content="Website Title"/>
<meta property="og:type" content="website"/>
<meta property="og:url" content="http://URL.com/"/>
<meta property="og:image" content="http://URL.com/img.png"/>
<meta property="og:site_name" content="Site Name"/>
<meta property="fb:admins" content="User_1"/>
<meta property="og:description" content="Website Descriptiom"/>
<!--Google+ Metadata /-->
<meta itemprop="name" content="Google+ ID">
<meta itemprop="description" content="Description">
<meta itemprop="image" content="Empty">
I have tried removing it and still the problem persists. I do want to point out that I have an html site with a wordpress blog that's being hosted on my server. Wondering if the issue might be with wordpress?
Should the metadata be placed on the index.html and the wordpress homepage or just the index.html? Any help would be appreciated. Thanks.
When you delete those metadata tags, specifically the og: ones (facebook's open graph meta tags) - you have to tell Facebook to pick up a new copy of your page as they cache everything. If you haven't tried this already:
Remove those tags
View the source on your live site, to confirm they are in fact removed
Go to http://developers.facebook.com/tools/debug and type in the URL of the page you are testing. This will tell Facebook to grab a new copy.
If that works (as it should), then you can play around with what tags to keep and how to make them dynamic - knowing that anytime you make a change, you will have to redo step #3 to tell FB to grab a fresh copy.

Facebook 'Like' counters not working as expected

I understand this is the main facebook developer community; I wanted to as a question and see if anyone can help?
I built a wordpress photo portfolio blog - http://shutterliving.com/movember-moustache/
I have the official facebook plugin installed and I have its own LIKE button running at the top and bottom of the page.
I also have the ‘TFG social share’ plugin installed:
wordpress.org/support/plugin/twitter-facebook-google-plusone-share
I am now wondering if I have managed to set it up correctly as I am encountering some unexpected behavior.
When I preview an unpublished post, the LIKE counter (for the official plugin) is at 0, however the ‘TFG social share’ plugin shows a 12 count? Why is there a discrepancy? How can the post get a like count if it has yet to be published? When I create a new post and save it as a draft, then preview it, both LIKE counts are at 0.
When I go to the debugger tool and input my URL I get errors that I don’t really understand, but a bit of googling told me they were not serious errors. Not sure though on how to fix them? Any idea?
Also when I click on my URL link in the Fetched URL and the Canonical URL, it takes me to a ‘Page not found’ page? Is this normal? Should it not take me through to my homepage?
Response Code 200
Fetched URL shutterliving.com
Canonical URL shutterliving.com
Open Graph Warnings That Should Be Fixed
Inferred Property The 'og:url' property should be explicitly provided, even if a value can be inferred from other tags.
Inferred Property The 'og:image' property should be explicitly provided, even if a value can be inferred from other tags.
Meta Tag <meta property="og:locale" content="en_US" />
Meta Tag <meta property="og:site_name" content="shutterLIVING" />
Meta Tag <meta property="og:type" content="website" />
Meta Tag <meta property="og:title" content="shutterLIVING" />
Meta Tag <meta property="og:description" content="Jamie A Cowan's PhotoBlog and Portfolio" />
Meta Tag <meta property="fb:app_id" content="178646462271083" />
I also associated the INSIGHTS analytics to my web page, however the information it shows is not accurate, ie it says I have only 55 LIKES on my page, however I have much more Likes that that
http://shutterliving.com/movember-moustache/
This leads me to believe I have set something up incorrectly.
Can anyone help with any issue
Jamie.

Like button image not showing in timeline

I used a Facebook like button on my website, but when I click the "like" button I don't see the image in my timeline. Everything else works fine.
I use this code:
<meta property="og:image" content="/images/fblogo.jpg"/>
The two other tags are working fine.
<meta property="og:title" content="..."/>
<meta property="og:site_name" content="..."/>
What am I doing wrong?
You must refer to your image as a fully qualified path (http://www.yourdomain.com/images/fblogo.jpg)
be sure you have prefix="og: http://ogp.me/ns#" in your html tag
also, to test - make sure you're using the facebook lint tool, so you defeat the caches of facebook. It also tells you when you have invalid tags and incorrect values for tags.
In got the same error, and solver it by adding property="og:description" to the meta description tag,
this solved my problem but I don´t know if Google likes it....

Any reason fb doesn't read meta tags for this share button?

I've looked through different posts here and couldn't find the answer..
check the source of http://he.thenamestork.com
<meta property="og:title" content="האתר שינחש את השם של תינוקך העתידי" />
<meta property="og:image" content="http://he.thenamestork.com/gfx/FBthumb.png" />
<meta property="og:url" content="http://he.thenamestork.com" />
this is generated by php. from some reason, fb totally ignores these meta tages when clicking share.
the WEIRED thing is -
a. the exact same code worked just fine before
b. when clicking 'share' from he.thenamestork.com/names/something - the meta tags DOES get read by fb, even though both the meta tags and the share button are generated by the SAME PHP FILES and implemented in the SAME WAY.
what's wrong?
Seems the problem was facebook's cache of previous share properties.
All I had to do was waiting.