“电话”,“短信”和“电子邮件地址”不再升级到科尔多瓦3.6.3后,Android的工作升级到、科尔、电子邮件地址、多瓦

2023-09-05 05:56:42 作者:一笑奈何

我最近升级我的科尔多瓦基于Android应用程序从3.5.0到3.6.3。特殊通电话,短信和电子邮件地址停止工作。单击时,没有任何反应。有什么我可以在AndroidManifest.xml,或Confix.xml或其他任何东西做,让他们回来工作?

I recently upgraded my cordova based Android app from 3.5.0 to 3.6.3. The special links "tel", "sms", and "mailto" stopped working. When clicked, nothing happens. Is there anything I can do in the AndroidManifest.xml, or Confix.xml or anything else to get them back working?

我建了两个相同的,很简单的Andr​​oid应用程序,以证明我的怀疑,其中一个科尔多瓦3.5.0和一个与3.6.3。他们都有一个简单的链接:

I built two identical and very simple android apps to prove my suspicion, one with cordova 3.5.0 and one with 3.6.3. Both of them have a simple link:

<a href="tel:1(858)xxx-xxxx">Call</a>

第一个工作,第二个是行不通的。

The first one works, the second one doesn't work.

我想他们增加了安全功能,阻止意图不知何故。

I think they added a security feature that blocks intents somehow.

PS:建这样这两个应用程序:

PS: both apps built like this:

cordova create app com.tmp.app "App"
cordova platform add android

和index.html中,我在上面添加的设备准备就绪块上的电话联系。

and in index.html, I added the telephone link above on the device ready block.

请帮忙。

推荐答案

我终于找到了答案。所有你需要做的是以下内容添加到config.xml文件:

I finally found the answer. All you have to do is add the following to config.xml:

<access origin="tel:*" launch-external="yes"/>
<access origin="geo:*" launch-external="yes"/>
<access origin="mailto:*" launch-external="yes"/>
<access origin="sms:*" launch-external="yes"/>
<access origin="market:*" launch-external="yes"/>

我希望这有助于大家。

I hope this helps everyone.

这一切都开始由IBM !!!

It all started by IBM!!!

IBM科尔多瓦安全问题

 
精彩推荐
图片推荐