javafacebookservletsapprequestsfacebook-app-requests

Facebook AppRequests + Browser Compatibility


I have a web based application that requires the functionality to "share the application" to the logged-in user's friends.

I generate a URL for this (see below) and it works, as it should, in:

  • Desktop Browsers
  • Android Chrome Browser
  • Android Firefox displays a blank screen while The "Internet" Browser (default shipped browser with most Android devices <4.4) shows:


    "Server Error
    The website encountered an error while retrieving [URL]. It may be down for maintenance or configured incorrectly.


    The URL generated (after www -> m redirecting) is :

    https://m.facebook.com/dialog/apprequests?app_id=[APP_ID]&message=[MESSAGE]&redirect_url=[CALLBACK URL]

    Another observation is that if I force the mobile browsers to render as a desktop web page, and replace m with www, it works fine...

    I am using Java Servlettes(with RestFB), jQuery (Base+Mobile) + HTML

    Would anyone know what I am missing for the other browsers? It seems odd that it works in some and not in others.


    Solution

  • For anyone's reference, it seems, like at this point in time, that I was trying to achieve something unrealisble with the Facebook API. I have since changed to the JavaScript SDK for Facebook, and the problem has disappeared.

    Smacking my head why I initially thought using the SDK would be overkill - so much easier to use!