0

I am trying to check if a contact exist already before creating it.

below is a sample of my code,

$contact_fields_index = array("name"=>"Paul Pierre", "mail"=>"paul@barnardmail.net");
$existingContacts = PodioContact::get_for_app( $PODIO_APPID , $contact_fields_index);

$existingContacts is always empty, even though the contact exists in the workspace.

What am I doing wrong ?

4

1 回答 1

0

我怀疑您的邮件可能不匹配,或者您的姓名不匹配。您是否尝试不使用属性参数?例如:

$existingContacts = PodioContact::get_for_app( $PODIO_APPID );

这应该会带回所有联系人,并且在输出 $existingContacts 数组时,您可以查看您要查找的联系人是否在其中。

于 2015-02-11T01:15:40.283 回答