Note that mozContacts is only available to privileged and certified applications: https://developer.mozilla.org/en-US/Firefox_OS/Security/Application_security

Cheers,
Josh

On 11/25/2013 03:41 AM, [email protected] wrote:
Em quinta-feira, 2 de maio de 2013 09h03min11s UTC-3, jose llopis  escreveu:
does it really works?

i need to check phone numbers in  my app and i'm not able to do this cant 
figure why...


PS: i have already set up the pertinent permission on the manifest file, my 
machine is w8 64 bit but i also have a vm  with ubuntu 13.04 and it does 
nothing :(

I'm having the same issue. I'm using the code copied from the documentation 
without any change:

var cursor = navigator.mozContacts.getAll({});

cursor.onsuccess = function() {
     if (cursor.result) {
         alert("Got contact with name: " + cursor.result.name.join(" "));
         cursor.continue();
     } else {
         alert("Done!");
     }
};

cursor.onerror = function() {
     alert("Error getting contacts");
};

But it just shows "Error getting contacts" (there are contacts in my list)


_______________________________________________
dev-b2g mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-b2g

Reply via email to