change the who of google calendar event with gdata framework
Posted
by bouth69
on Stack Overflow
See other posts from Stack Overflow
or by bouth69
Published on 2010-03-01T09:10:59Z
Indexed on
2010/04/19
20:23 UTC
Read the original article
Hit count: 263
$gdataCal= new Zend_gdata_calendar($client);
//on retrouve l'event a partir de eventURL stocké lors de la création
$event = $gdataCal->getCalendarEventEntry($id_event);
$who= $gdataCal->newWho();// $who objet de type Zend_Gdata_Extension_Who
//les nouvelles valeurs du who
$email ="cn21lqqt8jeb9qgulpra6bj948%40group.calendar.google.com";
$rel = 'http://schemas.google.com/g/2005#event.organizer' ;
$valueString ='alain developpeur';
$who->setEmail($email);
$who->setRel($rel);
$who->setValueString($valueString);
//$who->setDom($who_old[0]->getDOM());//bizarre mais???
//méthode magic ou setteurs
//$event->who= array($who);
$event->setWho($who);
//on affiche les propriétés du nouveau who pour voir les changements
echo'<br >lemail est : '.$who->getEmail();
echo'<br >la value string est : '.$who->getValueString();
echo'<br >la rel est : '.$who->getRel();
//on sauve on spécifie le type de classe dans lequel on veut sauver
// $event->save(Zend_Gdata_EventEntry);???
$event->save(Zend_Gdata_App_Entry);
thank you for yours answers.
© Stack Overflow or respective owner