gmail grabber bug
Brought to you by:
magnettech
I corrected a bug for the gmail grabber, if you had some contacts with only phone and no mail, the resulting list was getting offset... Here is the changed code:
(starting line 139 of libgmailer)
$html2 = str_replace("\n","",$html2);
$tempname = split('<b>All Contacts</b>',$html2,2); // start of contact list
preg_match_all('/<td><b>[^\<]*<.b><.td><td>[^\<]*@[^\<]*;/s', $tempname[1], $name);
$tot_contacts = sizeof($name[0]);
for($i=2,$j=4;$i<$tot_contacts;$i++,$j++)
{
$contact = split('</b></td><td>', $name[0][$i]);
$result['name'][]=trim(strip_tags($contact[0]));
$email = str_replace(" ","",$contact[1]);
$result['email'][]=trim(strip_tags($email));
}
return $result;
I am always getting "No contacts found" Please let me know how to get the contact list