I'm having a problem with the good ol' facebook like button on my site. I've implemented it all, I can click on "like" and it appears on my wall (and on the site the count pops up to say "1"), but the count never updates. If I refresh the page it just shows the "like" button again (no count), and if I log in to facebook with a new account and click on like again, it just says "1" again.
An example page on my site:
http://www.makemeacocktail.com/recipe/6741/
The fql readout (watch the apostrophe escape here, copy and paste dont just click):
https://api.facebook.com/method/fql.query?query=select%20total_count,like_count,comment_count,share_count,click_count%20from%20link_stat%20where%20url='http://www.makemeacocktail.com/recipe/6741/'&format=json
The FB XML that is being used:
<fb:like href="http://www.makemeacocktail.com/recipe/6741/" send="false" layout="button_count" width="50" show_faces="false" font="arial"></fb:like>
Other facebook thoughts etc:
I've got the facebook open graph meta data in the head
The js call to facebook happens as the last thing on my page, after the FBML:
<script src="http://connect.facebook.net/en_US/all.js#appId=187430904631019&xfbml=1"></script>
<script>
FB.init({
appId : '187430904631019',
status : true,
cookie : true,
xfbml : true
});
</script>
I've also got the facebook page like at the bottom of my page:
<div id="fb-root"></div><fb:like-box href="http://www.facebook.com/makemeacocktail" width="292" show_faces="false" stream="false" header="true"></fb:like-box>
Which is where the fb-root is.
My only thought it something about fb-root not being next to the facebook like button earlier up, and a conflict of two facebook like buttons or something? I;m only calling the facebook js once though, right at the bottom.
Any thoughts help etc much appreciated. It is weird because it it going to my wall, but the button on the site isn't listening!
Thanks a lot
Got this from the request your like button sends to facebook:
App ID does not match domain","full":"The app ID specified
within the \"fb:app_id\" meta tag is
not allowed on this domain. You must
setup the Connect Base Domains for
your app to be a prefix of
http:\/\/www.makemeacocktail.com\/recipe\/6741\/
So, you need to change the base domain for your application in the developers application to makemeacocktail.com. If that is not the problem try removing the fb:app_id open graph tag, or use the fb:admins tag instead. Good luck, hope this helps.
Related
I have added a facebook like button to my site at http://forkmyreligion.com. I have triple checked all the settings for the app on my developers.facebook page and I'm pretty sure its all correct - the domain is correct, the website url is correct and I have the correct app id for the application.
The problem though is that clicking on the like button results in the user liking the facebook social plugins page rather than my page.
Any ideas what the problem might be?
Thanks
The Like button on your page is Liking the social plugins page because the Like button on your page has a data-href parameter which is explicitly configuring the like button to like that URL:
You have this:
<div class="fb-like" data-href="https://developers.facebook.com/docs/plugins/" data-colorscheme="light" data-layout="standard" data-action="like" data-show-faces="true" data-send="false"></div>
You need to set the data-href to the URL you want the button to display and increment the like count of.
This parameter is mentioned on the Like button documentation and the example in the documentation is the URL https://developers.facebook.com/docs/plugins/
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'm using a 503 page as a 'coming soon' splash page. It has a FB like button on it.
I have been able to get the description and title to pull across, but the url of my site is wrong..
my normal url is like example.com, and the url displayed is my dev site - dev.example.com
I have searched all the files I can think of for dev. and can't find it anywhere..
Clicking the title link provided on facebook actually takes you to the correct url, but it's just the url displayed underneath that is visually wrong.
any ideas?
check the configuration of your app in fb or:
<div class="fb-like" data-href="YOUR_URL" data-send="true" data-width="450" data-show-faces="true"></div>
or
<fb:like href="YOUR_URL" send="true" width="450" show_faces="true"></fb:like>
Is there any server side redirection from your example.com to dev.example.com? The Like button script will resolve those and present the user with the end URL.
I have a Wordpress.org based website and I've set it up so that on each individual "post" page (single.php file) there's a Like button above the post so users can Like that individual post.
I was using iFrame and just switched over to XFBML but it didn't fix my problem. My code is:
<fb:like send="false" layout="button_count" width="80" show_faces="false"></fb:like>
The problem is when someone clicks "Like" it shows up in their "Other" Like activity on their Facebook page because I guess each post is considered it's own page. How can I make it so each post isn't considered a page and the Like results do not show up in someones "Other" activity?
My website is www.RockItPro.com and for example a single post url is http://www.rockitpro.com/2012/01/04/flyawayhook/
You could use a like button with a fixed url:
<fb:like href="http://example.com" send="true" width="450" show_faces="true"></fb:like>
That way you likes would end up summed to the page, on the other hand this defeats the purpose of liking those articles for the article as every user on facebook would get redirected to the fixed page.
To fix the Other-Category you will need to categorize your page. See https://developers.facebook.com/docs/opengraph/ for examples how to use so you can tag your ownership of the page and get admin permissions to it's facebook representation.
My FaceBook Page is setup so that users who have not "Liked" the page yet (and attempt to view the page) are presented with the content of a particular tab instead of the default "wall" view.
The tab that these users arrive at contains an application I made. It is a simple application that lists information about the business.
The application is using the "I Frame" render method (in the application's "Canvas" settings).
My goal is to add a FaceBook "Like Button" or "Like Box" inside my application.
The purpose of this is to write a message that encourages visitors to "Like" the FaceBook Page (not the application).
I've tried the FaceBook code generators for Like Buttons and Like Boxes, but it does not work. When I view my application in FaceBook, there is "nothing" in the location where I added the code.
Having a "Like" button inside of an application seems like something that many FaceBook page owners would want. Is there any way to accomplish this?
First of all, make sure you page is loaded in html mode instead of FBML.
1, Load the FB JS
<script src="http://connect.facebook.net/en_US/all.js#appId=YOURAPPID&xfbml=1"></script>
2, Init the FB (sometimes it doesn't work without this)
<script>
FB.init({
appId:"YOURAPPID",
xfbml:true,
status:true,
cookie:true,
});
</script>
3, Put the like button where do you want
<fb:like href="http://www.facebook.com/YOUR_FACEBOOK_PAGE" send="false" layout="button_count" width="90" show_faces="false" font="arial"></fb:like>
The like will appear, but will not make page refresh, so you have to take care the flow yourself.
Apparently like buttons aren't supported in the current implementation of FBML, which is the only language you can use inside the "tabs" on a facebook canvas page.
You may notice that a number of professionally done sites put a big arrow pointing up and then a "click the like button" text, without actually using a like button. This is why they do that.
Until facebook implements XFBML inside tabs, it looks like any XFBML only tags (such as fb:like) can only be used on your personal website. I think they do this for security reasons, although it does seem a little ridiculous that there are features you can use on your own page that facebook doesn't actually support on -their- pages.
The only workaround I have found is to include fb:comments tag in your app, which is an FBML tag that puts up a comments box AND a like button.
In order to get a Like button, go to http://developers.facebook.com/docs/reference/plugins/like, fill out the appropriate information and press "Get Code". This will open up a modal window with the necessary code. Copy that code into your program, and you're done.