Hi all,

I am blocked by a SecurityError when trying to retrieve the default address
book in a Web app.

Here is what I have :

1) An HTML file with a button calling a Javascript function :

<button onclick="add_contact()">Ajouter</button>

2) In the Javascript function, I try to retrieve the default address book
(this raises the SecurityError) :

var addressBook = tizen.contact.getDefaultAddressBook();

3) In my config.xml file, I have set read and write privileges for contacts
(the "read" one is necessary for getDefaultAddressBook according to the
documentation) :

<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns="http://www.w3.org/ns/widgets"; xmlns:tizen="
http://tizen.org/ns/widgets"; id="http://yourdomain/TizenDevlabContact";
version="1.0.0" viewmodes="maximized">
    <tizen:application id="SocHHBX9kD.TizenDevlabContact"
package="SocHHBX9kD" required_version="2.1"/>
<tizen:privilege name="http://tizen.org/privilege/contact.read"; />
 <tizen:privilege name="http://tizen.org/privilege/contact.write"; />
<content src="index.html"/>
    <icon src="icon.png"/>
    <name>TizenDevlabContact</name>
</widget>

Any idea what I am missing?

Jeremy
_______________________________________________
Application-dev mailing list
Application-dev@lists.tizen.org
https://lists.tizen.org/listinfo/application-dev

Reply via email to