演示代码
// 监听plusready事件 document.addEventListener("plusready", function() {}, false); function find() { plus.contacts.getAddressBook(plus.contacts.ADDRESSBOOK_PHONE, function(addressbook) { addressbook.find(["displayName", "phoneNumbers"], function(contacts) { alert(contacts.length); let str = JSON.stringify(contacts) console.log(str) }, function() { alert("error"); }, { multiple: true }); }, function(e) { alert("Get address book failed: " + e.message); }); }
Html5 plus 获取Android通讯录
- Tz
- 0