[英]Cordova call plugin error
First i was trying to do this without any plugin. 首先,我试图在没有任何插件的情况下执行此操作。 I had sanitized tel: in the code.
我已经在代码中清理了tel:。
<a href="tel:0038098754215">
, which was working from webpage but not from mobile android. <a href="tel:0038098754215">
,它可以从网页上运行,但不能从移动android系统上运行。 Then i tried to add this plugin Call Number which was added successfully but the code which i was running 然后我尝试添加此插件的电话号码 ,该电话号码已成功添加,但是我正在运行的代码
setTimeout(function(){
console.log('testing');
window.plugins.CallNumber.callNumber(function(res){
console.log('res');
console.log(res);
}, function(err){
console.log('err');
console.log(err);
}, '00380680576169', true);
},10000);
Had as result from browser 由于来自浏览器
testing
err
Missing Command Error
null
and from mobile: 并通过手机:
testing
null
And inside config.xml i am adding 在config.xml中,我正在添加
<access origin="tel:*" launch-external="yes" />
在config.xml中添加以下代码
<access origin="tel:*" launch-external="yes" />
Did you add your code inside the "DeviceReady" function? 您是否在“ DeviceReady”函数中添加了代码? Besides, I don't think you can test this plugin using the browser, but on the device only.
此外,我认为您无法使用浏览器测试此插件,而只能在设备上测试。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.