2

我正在尝试使用 Zend Gdata 库检索 Google 日历事件。

当我创建一个事件时,我将 insertevent 方法返回的事件 URL 存储在我的数据库中。最初我以为我可以使用此 URL 稍后删除该事件。经过一番研究,我意识到您实际上需要一个特殊的 URL,它是事件 URL,并附加了一个额外的数字字符串。我查看了 Zend Gdata 库中的各种事件检索方法,但它们似乎都不允许您只传递事件 URL。它们似乎都需要文本或日期范围查询。我将如何检索我已经知道其 URL 的事件的删除 URL?

4

1 回答 1

1

我最终意识到,当您使用 insertevent 方法时,您可以通过调用 $createdEvent->getEditLink()->href; 来查询编辑 url;例如:

// ... All the code to connect to the calendar and create the event
$createdEvent = $gCal->insertEvent($newEvent);
$link_gcal = $createdEvent->getEditLink()->href;

希望这可以帮助其他人。享受!

于 2010-02-15T08:01:56.780 回答