Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

FB.ui dialog not displayed on mobile devices

I am using FB.ui to trigger a requests dialog. The dialog loads properly on non-mobile devices. However, it fails to load on mobile devices like iPad. What appears is something like a popup/iframe with a loading-gif.

 FB.ui({
            method: 'apprequests', 
            message: 'Hello People',
            title: 'A friendly hello',
            data: 'some-data',
            display: 'touch',
            access_token: my_access_token,
        }, callback);

I have tried with display: 'iframe', display:'popup', display: 'wap' and display: 'page'. But nothing works. How can I get it working on mobile devices? Thank you.

like image 943
dheerosaur Avatar asked Jun 30 '11 10:06

dheerosaur


1 Answers

I used a URL redirect for my mobile devices like here: http://developers.facebook.com/docs/guides/mobile/#web

To display a mobile-friendly Feed Dialog, redirect the user to the following URL:

http://www.facebook.com/dialog/feed? client_id=YOUR_APP_ID&redirect_uri=YOUR_URL&display=touch

I assume it works similarly for the apprequests method you are using.

like image 151
Evan Layman Avatar answered Sep 29 '22 01:09

Evan Layman