Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Regular Visitor
Posts: 1
Registered: ‎11-09-2012
My Device: Dev alpha
My Carrier: Telkomsel

Using WebView to connect facebook on bb10

Hi there, 


I try to create native app using facebook api using the webview to get the URL link to retrieve the access token.  However, the webview won't display the redirected link from that API hence won't allow me get the result.  I did try using the normal browser and it works fine.  Really confused now, is it the webview on bb10 dev alpha not working properly with facebook redirect??


Anyone ever try to develop facebook connect App using bb10??  Please help....


note: I'm using cascade, bb10, dev alpha



Posts: 1,382
Registered: ‎07-02-2009
My Device: BlackBerry Bold 9900
My Carrier: Bell

Re: Using WebView to connect facebook on bb10

The following sample application demonstrates how to integrate OAuth with FaceBook using Web Apis. It uses a JavaScript library called jsOAuth to simplify the OAuth process.


Although this sample is published in a WebWorks folder, it should also work in a Cascades + webview hybrid app as well (currently does not have any WebWorks-specific dependencies):




Note, FaceBook requires an additional "piece" for its OAuth - you must  provide an external URL that Facebook will redirect to once it has authenticated.  This is unlike other service providers that use OAuth (such as Foursquare), where you can simply redirect back to local://index.html

Follow me on Twitter: @n_adam_stanley
Your app doesn't work? Use BlackBerry remote web inspector to find out why.