Facebook canvas app vs Facebook for mobile applications

I am a bit confused by the difference between facebook canvas app and facebook mobile web app. This is the context of my confusion.

I have a canvas app, let's name its namespace as myfbapp, and I can basically access it from https://apps.facebook.com/myfbapp , and after I enter FB, it opens from Facebook I use java (apache / tomcat) for my server-side implementation, and for simplicity, let's say I only have index.html and authenticationfilter.java (which implements Filter) in my web application. I don't have a Facebook specific Javascript API (without Javascript FB.init () or anything like that) or the code in my index.html. Whenever a user accesses my canvas application, I first receive a request to my web application, where I get signed_request, oauth_token, FB user ID, etc., which I can use for my internal authentication, create a session etc. I have absolutely no problems with this canvas app and everything works fine. Please note that when a user accesses this application, the request that I receive from the browser to my application server has signed_request, user_id, etc.

Now I wanted to make this application available on mobile devices, and I thought that all I need to do is add the mobile URL for this application in the mobile web application section of Facebook for the same myfbapp. I did this and, as expected, when I log into facebook from my android myfbapp phone, it’s indicated in the apps section how good this is. The problem starts when I click on the application. I get a request on my application server, but it does not contain signed_request, user_id, etc. ????? I was expecting the mobile app to work just like the canvas app, but apparently this is not the case, or I'm doing something wrong.

Then I started reading more about the facebook mobile app at http://developers.facebook.com/docs/guides/mobile/web/#register , where he talks about adding javascript to the javascript index API in JavaScript (I never did anything in my canvas application), and then I started to think, maybe then the mobile web application is more (or for sure), like a regular web application with an FB connection, and not like a canvas application (this means that it doesn’t load on it on Facebook) is this true?

+7
source share
2 answers

On mobile facebook you do not see any user pages / tabs. At the moment, they are apparently participating in this.

This way it will be different from the canvas application. Your mobile application will be a completely separate site and non-iFrame page on Facebook.

+12
source

Some behavior I recently discovered using Facebook Canvas / Page Tabs on mobile devices. Perhaps this helps to understand a little better how facebook works in a mobile context.


Mobile browser

Access URL

Sample URL http://apps.facebook.com/myapp/

Redirects to the configured mobile site under Settings > Website > Mobile Site URL and adds additional parameters /?ref=web_canvas&code=<signed_request_code_field>

About the signed_request code field

OAuth code that can be exchanged for a valid user access token through a subsequent server-side request

Application Access Center

The mobile browser does not have access to the Facebook Application Center.

Access Page Tab

Example URL http://facebook.com/a_facebook_page/custom_page_tab_url

Custom page tabs are not displayed through the mobile browser.

Facebook Open Graphic Search

A search of myapp returns a link to a Facebook canvas.

Same behavior as Access app URL via mobile browser


Facebook Mobile Client

Access URL

There is no direct access to this url.

Application Access Center

No access to Facebook Application Center.

Access Page Tab

Example URL http://facebook.com/a_facebook_page/custom_page_tab_url

Custom page tabs are not displayed through the Facebook mobile client.

Facebook Open Graphic Search

It says that this application is not compatible with these devices.

You need to register the iOS / Android application and send the user to this application to get rid of this error. This probably helps the user to add a link to a separate application in the application description on Facebook. Which then should be seen there.

+1
source

All Articles