Cordova 短信插件
Cordova sms plugin
我正在使用 apache Cordova 短信插件编写一个 visual studio 2015 项目。
我写了这个小代码
function InviaSms()
{
var number = document.querySelector("#numberTxt").value;
var message = document.querySelector("#messageTxt").value;
//configurazione
var options = {
replaceLineBreaks: false, // true to replace \n by a new line, false by default
android: {
//intent: 'INTENT' // send SMS with the native android SMS messaging
intent: '' // send SMS without open any other app
}
};
var success = function () { $('#erroresms').text = 'Message sent successfully'; };
var error = function (e) { $('#erroresms').text = e; };
sms.send(number, message, options, success, error);
}
它在 android 平台上运行良好,但是当我将它部署为 Windows Phone 时,通用应用短信功能不起作用。
谢谢
为了Windows通用,就是"cleanest"做这个纯粹是在Javascript看这个https://github.com/cordova-sms/cordova-sms-plugin/issues/31
我正在使用 apache Cordova 短信插件编写一个 visual studio 2015 项目。 我写了这个小代码
function InviaSms()
{
var number = document.querySelector("#numberTxt").value;
var message = document.querySelector("#messageTxt").value;
//configurazione
var options = {
replaceLineBreaks: false, // true to replace \n by a new line, false by default
android: {
//intent: 'INTENT' // send SMS with the native android SMS messaging
intent: '' // send SMS without open any other app
}
};
var success = function () { $('#erroresms').text = 'Message sent successfully'; };
var error = function (e) { $('#erroresms').text = e; };
sms.send(number, message, options, success, error);
}
它在 android 平台上运行良好,但是当我将它部署为 Windows Phone 时,通用应用短信功能不起作用。
谢谢
为了Windows通用,就是"cleanest"做这个纯粹是在Javascript看这个https://github.com/cordova-sms/cordova-sms-plugin/issues/31