Is user authorized, on Facebook tab - facebook

Getting an interesting error. I've been developing and application, and viewing it on it's page. Now I'm install that app in as tab on a company page and it's saying I can't use:
<fb:if-is-app-user>
in the tab view? How can I show or hide part of the page if the user viewing it is an app user?

FBML fan page tabs have been deprecated and replaced with Facebook iframe pages. To determine if the user is fan, you will need to decode the signed_request parameter that gets POST'ed to your webpage. There will be a "liked" variable in the encoded json payload. This page gives an example of how the new process works,

Related

Add Facebook App to Facebook Page

All,
I created a facebook application in the developers.facebook.com. Then on the basic page under how it integrates with Facebook I select Page Tab. I supplied the information because I'm hosting the page and now I want to display it on my Facebook page.
How can I actually display this application on my facebook page?
Thanks!
Adding as an answer for future reference:
Check http://developers.facebook.com/docs/appsonfacebook/pagetabs and make sure you've added all the fields necessary for the 'Add Page Tab' dialog to work; most likely the dialog will fail with Error 191 if you've included a redirect_uri field with a URL other than the one in your Page Tab Url or Site Url

Facebook page get user like status

I tried googling & checking stackoverflow for the possible solution but haven't found any yet, so would like to bring it up here again.
I have a Facebook page, page has multiple tabs, and one of the tab has a Facebook App (accessed only through the tab, redirect the http://apps.facebook.com/myapp to the page tab)
I have some content (say non-fan content) to be displayed to the user before he likes the page.but, I don't have any way to check if the user has liked the page unless he adds the app & fb documentation has stuff that can give me the required like FQL page_fan, url_like, api(/me/likes/FACEBOOK_PAGE_ID) but each one of this needs an accesstoken (which I cannot get before the user adds the app).
some of the posts on stackover flow says that is not possible without getting the user to add the app. but there are apps like static html, static iframe & others which provides this functionality, how ?
Please advise.
Facebook will POST a signed_request to your server when the user opens the page tab.
This is what you get when you parse the signed_request:
{
"algorithm":"HMAC-SHA256",
"issued_at":1309468031,
"page":{
"id":"xxxxxxxxxxxxxxx",
"liked":true,"admin":true
},
"user":{"country":"fr","locale":"en_US","age":{"min":21}
}
The important part is "page.liked" where you see if the user likes the page.
No permissions and no app authorization is needed for this to work.
Search the web about parsing the signed_request in your favorite web programming language i.e. php.

Facebook navigate into subpage of page tab app via Browser Url?

is it possible to access a subpage of a page tab app in Facebook via the browser URL? I've programed a lottery game where the users can share/like/send each single post to their wall/friends. The Like-Urls of the Posts link to the plain web-page out of Facebook (e.g. http://my-own-app.com/post/the-post-slug/). But I want to target the URLs to the page tab app directly so that the Facebook will passthrough the data to the app (loaded by iframe) e.g. http ://www.facebook.com/pages/My-Page-Where-the-app-is-included/123456789?sk=app_my-app&passthrough-url=http...
<- is sth. like this possible???
Thanks in advance,
greetings
mbx
This is covered in the Page Tab App Documentation near the bottom - see the section marked 'Integrating with Facebook APIs'
Short version: whatever you pass in the app_data parameter as a GET parameter will be passed to your app in the signed_request (in a parameter also called app_data) sent to your app.

How to capture facebook page's like event in app? [duplicate]

I am planning to create some dynamic content in a Facebook tab for my fan page. It should have content displayed if the visitor is not a fan, and then upon them clicking the Like button, changing the content to display hidden carrots (metaphorically). Is it possible to capture the event of the click on the Like button from inside the iframe?
On a Facebook fan page, when the user clicks the Like button, the whole page gets reloaded and Facebook sends an HTTP post to your website with a parameter called signed_request that you would need to decode and look at with server code, not javascript. The code to decode it will obviously vary depending on what language you are using, but the process is documented on Facebooks site. Once decoded, you will need to look at the page.liked value.

facebook landing page

i have one problem with facebook landing page. i created facebook landing page through static fbml app but i have one problem with like button, user must like the page before he will navigate to another page.
i want to do same functionality in my landing page,
http://www.facebook.com/BusinessofCinema?v=app_6009294086.
anyone know about this please help me .
thanks inadvance......
At this point you'll probably want to go with iframe based Facebook page tabs instead, now that these have become available and fbml based apps are being phased out. Among other advantages, the signed_request parameter that Facebook sends to an iframe based tab app includes a flag that indicates whether the user is a fan of the page.
Now that iframes are the only way to create new Facebook apps and FBML is being phased out, you need a new way to do it.
When your app URL is loaded, it is passed a signed_request POST parameter. This parameter contains the information you need. However, it is packed and encoded so it requires some manipulation to get the right info out.
First, split the signed_request on the '.' character. The first part is the signature. The second part is the encoded_data
Decode the encoded_data into a JSON string using the URLBase64Decode function equivalent in your server-side programming language
The JSON object contains a node called "page". This contains a node called "liked".
If "liked" is true, the user liked the page and you display the "liked" version of your app. If false, show the "Please like me" version of the site.
The FBML way will continue to work the way you have it live right now, but for anyone building a new Facebook app, this is the way to do.