0

我已经看到本地应用程序这样做,并想知道是否可以使用 PhoneGap:

应用程序 A 向用户呈现一个操作,并在单击时将应用程序 B 加载到某个部分。

用例:Siri 向餐厅提供地址,点击后可打开指向该地址的地图,以便指示方向。

问题是,使用PhoneGap App A 是否可以打开App B 而不仅仅是打开它,而是将其打开到特定部分?

4

1 回答 1

1

You want to look at URL Schemes. Basically you make sure your application URL and custom Query-strings and when phonegap loads it listens to the incoming url and passes it on to Javascript to be used.

For example I can load up the native twitter app on my iphone by using

twitter:///user?screen_name=myusername 

So you can register myFabApp://object1=blah&object2=blah

Here is more information about using it in Phonegap Javascript https://github.com/apache/incubator-cordova-ios/blob/master/guides/Cordova%20Custom%20URL%20Scheme%20Handling.md

Then once you have the values in your app you can do what ever actions you like .

If this helped please up-vote :-)

于 2013-04-11T00:20:11.687 回答