dongpuchao1680 2013-11-21 09:21
浏览 28
已采纳

如何使用Google Calendar php api扩展属性

I have been struggling with the php api for Google Calendar for weeks now. I have already managed to add and read events with the api and now I'm trying to get Extended Properies to work. I have tried two different ways of adding them to my events:
1:

$extProp = New Google_EventExtendedProperties('test', 'test');
$event->setExtendedProperty($extProps);

2:

$extProp = New Google_EventExtendedProperties('test', 'test');
$event->ExtendedProperty = $extProps;

Both don't give me errors, but I'm not sure if it's working. I tried to read the events with the get method as well as with the list method wich are both described in the documentation of the api, but I can't get my extended properties.

Does anyone know how extended properties work with php?

  • 写回答

2条回答 默认 最新

  • dongyizhuang0134 2013-11-21 09:39
    关注

    I finally managed to do it. I used the following code:

    $extendedProperties = New Google_EventExtendedProperties();
    $extendedProperties->setShared(array('custom'=>'blalblabla'));
    $event->setExtendedProperties($extendedProperties); 
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 对于相关问题的求解与代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 信号傅里叶变换在matlab上遇到的小问题请求帮助
  • ¥15 保护模式-系统加载-段寄存器
  • ¥15 电脑桌面设定一个区域禁止鼠标操作
  • ¥15 求NPF226060磁芯的详细资料
  • ¥15 使用R语言marginaleffects包进行边际效应图绘制
  • ¥20 usb设备兼容性问题
  • ¥15 错误(10048): “调用exui内部功能”库命令的参数“参数4”不能接受空数据。怎么解决啊
  • ¥15 安装svn网络有问题怎么办