fixed not working calendar sync in RC1: re-add version parameter

This commit is contained in:
Ralf Becker 2005-11-18 14:47:27 +00:00
parent b3422af9ee
commit b7a2d57d47

View File

@ -85,7 +85,7 @@
* @param string $method='PUBLISH' * @param string $method='PUBLISH'
* @return string/boolean string with vCal or false on error (eg. no permission to read the event) * @return string/boolean string with vCal or false on error (eg. no permission to read the event)
*/ */
function &exportVCal($events,$method='PUBLISH') function &exportVCal($events,$version='1.0', $method='PUBLISH')
{ {
$egwSupportedFields = array( $egwSupportedFields = array(
'CLASS' => array('dbName' => 'public'), 'CLASS' => array('dbName' => 'public'),
@ -109,7 +109,7 @@
$vcal = &new Horde_iCalendar; $vcal = &new Horde_iCalendar;
$vcal->setAttribute('PRODID','-//eGroupWare//NONSGML eGroupWare Calendar '.$GLOBALS['egw_info']['apps']['calendar']['version'].'//'. $vcal->setAttribute('PRODID','-//eGroupWare//NONSGML eGroupWare Calendar '.$GLOBALS['egw_info']['apps']['calendar']['version'].'//'.
strtoupper($GLOBALS['egw_info']['user']['preferences']['common']['lang'])); strtoupper($GLOBALS['egw_info']['user']['preferences']['common']['lang']));
$vcal->setAttribute('VERSION','2.0'); $vcal->setAttribute('VERSION',$version);
$vcal->setAttribute('METHOD',$method); $vcal->setAttribute('METHOD',$method);
if (!is_array($events)) $events = array($events); if (!is_array($events)) $events = array($events);