I have an issue with the FB like button.
In a web view inside our iOS and Android apps, when the FB like button is pressed and you are not logged in, instead of displaying a login modal as it has previously it just disappears.
This happens for the iframe and XFBML versions.
I can also reproduce this when clicking the like button in the mobile browser when viewing https://developers.facebook.com/docs/reference/plugins/like/.
I've logged this with FB Dev but thought I'd try here as well.
I had the same problem....
You have to use this tool: https://developers.facebook.com/tools/debug
Enter the url you want to add like button, this will clear facebook cache,
and the like button will work properly.
It's possible a like button is blocked if the page it links to has a restriction. This article has some more information about this problem: Ttp://www.andreavahl.com/facebook/why-your-facebook-like-box-is-not-showing-up.php
Related
I have a like button on a page that includes all open graph tags required and which is validated by the Facebook debugger. See the debugger results here:
http://developers.facebook.com/tools/debug/og/object?q=http%3A%2F%2Fclasstivity.com%2Fiyengar-yoga-institute-nyc
When pressing like on the site, the page is displayed in the Facebook timeline as:
- no image, just the icon of a flag
- in the like box with likes for Facebook pages (which is separate from the like box module with pages liked on other websites)
The page requires regular visiting users to sign in but the Facebook user agent is allowed to see the page, thus the successful result from the Facebook debugger (link above).
The like button is used is the iframe one. Entering the URL for the page in the page where you generate a like button and hitting like there produces the same results however.
Has anyone experienced this issue and/or know a solution?
This is my app page: https://www.facebook.com/pages/When-Biebs-Attack/402350233140999
As you can see, it's an actual "App Page", created from my app control panel. So you would assume it would be linked with the app.
Now here is the (only) site that uses the App ID for a like button: http://cosmati.net/biebsattack/
Not only is the discrepancy weird, but as soon as I added the like button to the page it had 22 likes. I have double checked my App ID in my code. It does line up with my app control panel. I tried both the HTML5 and the XFBML methods.
okay, I don't know why it's doing what it's doing, but I figured out you can link them directly by adding an href tag to the like button and pointing it to the url of your facebook page. For instance, my like button now looks like this:
<fb:like href="https://www.facebook.com/pages/When-Biebs-Attack/402350233140999" send="false" width="450" show_faces="true" font="arial"></fb:like>
And now when I visit my site (http://cosmati.net/biebsattack/), not only do I only see 1 like (mine), but I see links to administer my page and view insights. Kind of neat. Not sure why it doesn't do this by default when I use the App ID, but whatever.
I have a like button on my website, which has a corresponding FB page and App. The like button is functional and has been for a while. I recently decided to add a subscribe button to my webpage, so that users could get updates on our content, posted directly to their wall, if they chose to. However, although I have generated the subscribe button code directly from the FB developers page with the correct App ID, the subscribe button does not show up or function when the code is inserted into my webpage. I am not sure if this is a conflict with the pre-existing like button. I have tried all 3 variations of the subscribe button, but none of them are showing up when tested locally or on the server.
So, first, please clarify if the subscribe button would indeed allow subscribers to get updates from our FB page that they subscribe to. And if that is the case, why can I not activate it on my website?
I have an iframe application.
When a user and another page and log in to facebook site, the application page is reloaded by facebook.
But, I want to reload the page in the logout state also.
Here is the scenario:
A user enters my iframe application and authorizes my app and successfully enters my app.
While using my app, the user opens my app (or fb site) in another browser tab.
The user logs out from facebook site in the last browser tab.
When user logs out from facebook, I want to automatically reload my application page in the browser.
How can I do this?
Have a look at FB.Event.subscribe, I think you should be able to use it to reload the page when the user's session changes.
Add something like this to your FB.init:
FB.Event.subscribe("auth.sessionChange", handleSessionChange);
...and the handleSessionChange callback function would look something like this:
function handleSessionChange(response) {
if(!response.session || response.session.uid!="$user_id"){
window.location.reload();
}
}
Unfortunately, your options are limited as communication with an IFRAME is very constrained. This may help you:
http://www.dyn-web.com/tutorials/iframes/refs.php
I have just implemented FB login and status updates in my app following the sample app in the IOS SDK.
I know it is common practice to have a like button for a page but is it also true for an app?
I mean is it possible to have a like button in my app that when tapped makes an entry on my FB page stating I like the app?
I can't seem to track the like feature down in the docs :-(
Thanks
basically you can add UIWebView and put your html tags inside it
check this and this sample they may help you