开发者

How to call android application from web browser

开发者 https://www.devze.com 2022-12-29 14:35 出处:网络
I want to call android application on开发者_运维问答 clicking of button on some website from mobile.

I want to call android application on开发者_运维问答 clicking of button on some website from mobile. Suppose I am opening one url on android browser and I want to call my application on clicking on button provided by that site. How to do that??

Suppose we are using browser other than Chrome then is it allowing??


If you link to your application as "myapp://foo/bar", can't you use some sort of intent filter to start your application.

I mean, if you press a youtube link in the browser it asks if you want to complete the action with the YouTube app or the browser.

I have seen similar examples regarding Google Maps links (which would open in either browser, google maps(?) or GeoBeagle).


Please take a look at the WebViewDemo. Javascript code in the web page can call into your Activity. As well as the other way around.


You cannot... if the site is being browsed in the default browser (Chrome).

If you already have an application that embeds the WebView, then you can do some bit of handling of - mouse clicks, window alerts, navigation etc. Otherwise, not!

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号