I've added fb:comments to a page that sits in an IFrame in another page. If the user clicks the "Post comment to my Facebook profile" the source URL posted on their Facebook wall is the IFrame source, and not the parent page. Is there a way to change this URL in the fb:comment options?
I've tried the callbackurl & returnurl options, and neither of those work. Also, setting opengraph meta tags on the IFrame source doesn't work either.
*edit: Code requested
<fb:comments canpost='false'></fb:comments>
If you know the parent page url, set it in the href value of the comments plugin like this:
<fb:comments href="http://urlOfOuterPage.com"></fb:comments>
Related
I am working on the embeddable quiz widget. Let's say we have page with quiz iFrame http://page.com/quiz, iframe src is http://quizes.com/quizes/1. I use this JS code to init Facebook share button:
FB.ui({
method: 'share',
href: 'http://quizes.com/quizes/1?result_id=2'
});
At http://quizes.com/quizes/1?result_id=2 we render og:title, og:description and og:image based on user result. The thing is that if quiz is embedded in Facebook post I want to see parent domain (page.com) but it is quizes.com (gistroll.com– real project domain).
I tried to pass parent page url to share link like this: http://quizes.com/quizes/1?result_id=2&url=http://page.com/quiz and use url in og:url, but Facebook Crawler follows http://page.com/quiz in this case and of course there are wrong og meta tags there.
Question: Any ideas how fix that and show different domain in Facebook feed? (May be we can pass all necessary params with JS?)
With migration of facebook like button, the recommended approach is to point href of the like button to the Facebook Page, but keep the og:url tag on the page the same. What are the results of this:
1)Are the users going to see posted hrefs to A)the facebook page or B)the page specified in the og:url tag?
2)What url are the shares going to be counted against:A)the facebook page or B)the page specified in the og:url tag?
I am using facebook like social plugin as follows.
<fb:like send="true" width="320" show_faces="true" font=""></fb:like>
If there is no href defined, this is said to be pick the current page.
I have a news website and I just want to integrate this like plugin per page, and when someone like a specific news page, i want that to be displayed in user profile.
However this is not the case right now.
I have debug it with firebug and it s getting/sending correct URL to facebook but on facebook profile, i dont see that URL that was liked.
How can i do that?
Why don’t you just put the actual URL into the href attribute of fb:like …?
i want to place a comment box at the bottom of a page tab/canvas page so that visitors can post comments that will be shown on that page and - if the user checks the checkbox - at the visitor's wall. I do this with the comments plugin
<div class="fb-comments" data-href="[link to real url of this page]" data-num-posts="2" data-width="520"></div>
The comment looks nice in the comments box. The comment looks ugly at the visitor's wall. The comment at the visitor's wall seems to gather the meta tag information of the comments box page. I have customized the meta tags according to http://developers.facebook.com/docs/opengraph/ and tested the setting by the facebook linter at http://developers.facebook.com/tools/debug with a good result. Now the comment at the visitor's wall looks fine with some small problems:
the comment does not link to the facebook-url (http://www.facebook.com/pages/..) but to the real url of the page (http://www.somewhere.com/page-with-comments.php) which is not desired
the comment contains a link pointing to the real url, which is not desired at all
For (2) i had a similiar problem when generating a post at the visitor's wall by
FB.api('/me/feed', 'post', { picture: pic, caption: ' ', description: desc, link: link }, function(response) {});
but then the link could be avoided by setting a caption attribute of one empty space. Unfortunately this attribute (og:caption) seems not be liked by the facebook linter. For (1) i have no idea how to solve the problem as the linter does not like any facebook-urls in the meta tag og:url, which on the other hand is responsable for the link target of the comment at the visitor's wall. This is not good.
Long message short, how do you implement the comments plugin on a page tab/canvas page with a nice look of the comment at the visitor's wall and a link at the comment to the page tab/canvas page.
Thanks a lot
In order to obtain what you are looking for, you have to add the Open Graph meta tags to the page that you're using as href in the fb-comments div.
The description of the supported tags is here: http://developers.facebook.com/docs/share/
You can check what the facebook scraper sees when reading your page by using the debugger tool here:
http://developers.facebook.com/tools/debug
I have a Facebook Application with an iframe based canvas that contains a like button (also iframe), in the head of my iframe i've specified the standard meta tags (og:title, og:url, og:site_name) and they seem to work fine (the information is displayed correctly in the profile wall) except for the title.
I've tested various links of the app with the Facebook URL Linter and the ug:title tag is ignored completly.
Have any of you had any trouble with the open graph tags inside facebook applications?
Any ideeas are apreciated, thanks.
I've tried every possible combination and suggestion in adding og meta tags to my page, but none of them worked. When testing URL with facebook URL Linter it always returned default values defined on application admin page. Like it doesn't see og meta tags. And what was more interesting is that when I look the page source, og meta tags existed but haven't been evaluated by facebook or linter.
Now, in my canvas page I defined login/authentication (and depending redirection etc) at the top, before html and og meta tags definition, and that was the main problem.
If you perform FB login redirection/authentication before providing og meta tags,
then FB crawlers/linter will not be able to detect your meta info and will try to auto-fill it.
I'm having the same problem in my app http://apps.facebook.com/tripline It seems that Facebook doesn't process links to pages inside apps the same way as pages they hit directly.
You can see the difference in the URL Linter:
The og:url on the canvas page: http://apps.facebook.com/tripline/trip.php?id=2015071615051003BEE6FBED6F531103 (og:title is ignored, get trip.php instead)
The url to the actual page loaded in the iframe: http://www.tripline.net/api/fbcanvas/trip.php?id=2015071615051003BEE6FBED6F531103#frame-top (og:title correct, but can't link to this because it's not in the frame)
The page on the main site: http://www.tripline.net/trip/The_Boston_Freedom_Trail-2015071615051003BEE6FBED6F531103 (og:title correct, if i can't figure things out, i'm just going to set the og:url on the canvas page to this)
Not really an answer, but at least you know you're not alone or crazy...which is worth something.