拨打电话:
tel:<电话号码>
<a href="tel:10086" >移动客服</a>
短信
sms:<电话号码>?<参数>
<a href="sms:10086">短信</a>
<a href="sms:10086?body=CXYE">带内容短信</a>
在 config.xml 中添加对应权限(测试通过 cordova 3.6 + )
|
1
2
3
4
5
|
<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"/> |
更多请参照:http://rickluna.com/wp/2012/02/making-a-phone-call-from-within-phonegap-in-android-and-ios/

本文提供了一种在Cordova应用中添加拨打电话和发送短信权限的方法,包括如何在config.xml文件中配置相关权限,以及实现拨打电话和发送短信的功能。详细步骤确保应用在Android和iOS平台上正常工作。
1848

被折叠的 条评论
为什么被折叠?



