我为此创建了一个丝网。 在与电话交换台合作时,需要:
- Add the Java file in the /src folder
- Update your /res/xml/config.xml for your Phonegap plugin settings
- Call your the plugin with cordova.exec() in your HTML/Javascript
Doeck the 如果需要额外指导的话。
您可以下载我的AlertDialog List plugin at github。
假设您的电话灯光灯光灯和粉碎机在您的超文本/日文中妥善铺设,你可以这样说。
<script>
var fruitlist = [
"The Fruit List Title", // this is the title
"Orange",
"Apple",
"Watermelon",
"Papaya",
"Banana",
"Pear"
];
function showlist(thelist) {
cordova.exec(
function(listitem) {
alert( "You selected "+ thelist[listitem] );
},
function(error) {
alert("Error Occured");
}, "AlertList", "alertlist", thelist );
}
</script>
<a href="javascript:showlist(fruitlist)">Pick your fruit</a>
I think I should also remind you that you need to load cordova
properly in your HTML/Javascript. We do that by listening to deviceready event. Otherwise, cordova.exec won t work. This is like the $(document).ready in jQuery.
document.addEventListener("deviceready", your_function, false);
www.un.org/spanish/ecosoc 2. 预警清单