mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-28 09:38:53 +01:00
Fix Funambol Outlook Client Issues
This commit is contained in:
parent
71dfd3b2bb
commit
81afb6f8e9
@ -1014,24 +1014,15 @@ class addressbook_vcal extends addressbook_bo
|
|||||||
#error_log(print_r($vcardValues, true));
|
#error_log(print_r($vcardValues, true));
|
||||||
Horde::logMessage("vCalAddressbook vcardtoegw: " . print_r($vcardValues, true), __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
Horde::logMessage("vCalAddressbook vcardtoegw: " . print_r($vcardValues, true), __FILE__, __LINE__, PEAR_LOG_DEBUG);
|
||||||
|
|
||||||
$email = 0;
|
$email = 1;
|
||||||
$tel = 1;
|
$tel = 1;
|
||||||
$cell = 1;
|
$cell = 1;
|
||||||
$url = 0;
|
$url = 1;
|
||||||
$pref_tel = false;
|
$pref_tel = false;
|
||||||
|
|
||||||
foreach($vcardValues as $key => $vcardRow)
|
foreach($vcardValues as $key => $vcardRow)
|
||||||
{
|
{
|
||||||
$rowName = strtoupper($vcardRow['name']);
|
$rowName = strtoupper($vcardRow['name']);
|
||||||
switch ($rowName)
|
|
||||||
{
|
|
||||||
case 'EMAIL':
|
|
||||||
$email++;
|
|
||||||
break;
|
|
||||||
case 'URL':
|
|
||||||
$url++;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
if ($vcardRow['value'] == '' && implode('', $vcardRow['values']) == '')
|
if ($vcardRow['value'] == '' && implode('', $vcardRow['values']) == '')
|
||||||
{
|
{
|
||||||
unset($vcardRow);
|
unset($vcardRow);
|
||||||
@ -1095,7 +1086,7 @@ class addressbook_vcal extends addressbook_bo
|
|||||||
break;
|
break;
|
||||||
//case 'INTERNET':
|
//case 'INTERNET':
|
||||||
case 'PREF':
|
case 'PREF':
|
||||||
if (strtoupper($vcardRow['name']) == 'TEL')
|
if (strtoupper($vcardRow['name']) == 'TEL' && !$pref_tel)
|
||||||
{
|
{
|
||||||
$pref_tel = $key;
|
$pref_tel = $key;
|
||||||
}
|
}
|
||||||
@ -1114,13 +1105,18 @@ class addressbook_vcal extends addressbook_bo
|
|||||||
$rowName = 'TEL;CAR';
|
$rowName = 'TEL;CAR';
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
if (strpos($pname, 'X-FUNAMBOL-') === 0)
|
||||||
|
{
|
||||||
|
// Propriatary Funambol extension will be ignored
|
||||||
|
$rowName .= ';' . $pname;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if($rowName == 'EMAIL')
|
if($rowName == 'EMAIL')
|
||||||
{
|
{
|
||||||
$rowName .= ';X-egw-Ref' . $email;
|
$rowName .= ';X-egw-Ref' . $email++;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(($rowName == 'TEL;CELL') ||
|
if(($rowName == 'TEL;CELL') ||
|
||||||
@ -1137,7 +1133,7 @@ class addressbook_vcal extends addressbook_bo
|
|||||||
|
|
||||||
if($rowName == 'URL')
|
if($rowName == 'URL')
|
||||||
{
|
{
|
||||||
$rowName = 'URL;X-egw-Ref' . $url;
|
$rowName = 'URL;X-egw-Ref' . $url++;
|
||||||
}
|
}
|
||||||
|
|
||||||
$rowNames[$rowName] = $key;
|
$rowNames[$rowName] = $key;
|
||||||
|
Loading…
Reference in New Issue
Block a user