Thursday 27 April 2017

Detect if in webview, if so, open url in default browser

Working with Facebook messenger as a way to send invitation links when working with mobile devices. Some reason, facebook messenger, sharing doesn't like history mode. I've tried turning history mode off and changing a few things with no luck. Ended using a different url. I'm using vue 2.0, vue router, vue-resource and facebook sdk among other things. Node, nginx.

Anyways, is there a way, perhaps a button, on page load, where I can take the opened link in facebook messengers webview and force mobile devices to open externally? Facebooks messenger webview is giving my site a few problems, especially when dealing with urls.

Detecting the webview is easy, but how to load url in external default browser??? Been searching forever, maybe not possible in javascript, web?

I know users can set their settings to open externally, but I want to make it easy. Thanks!



via Kaiser

No comments:

Post a Comment