I tried to answer this Google question, but no luck, maybe due to the fact that the search string "Z" was not specific enough.
Background:
Using the Google Calendar Zend gdata library, and used simple code to display events for a specific period of time. In this case, from 02/27/2012 to 03/03/2012. I had several separate events listed, with one recurring event called "Rob", weekly. I use the base code without any fancy add-ons. still:)
Problem:
when I used the parameter $query->setSingleEvents(TRUE), everything worked as expected and showed the correct events.
When I talk about "showing" events, I'm talking about a PHP page that uses Zend gdata to display calendar events.
In all situations, the Google Calendar GUI shows the correct data (i.e. the Rob event is not displayed because it was deleted.
But when I set this value to FALSE, the repeating βRobβ event should have a start time that should be grouped, but instead some extra random events are shown without starttime, the same title. Even when Ive deleted the recurring event, it is still displayed in the data returned by gdata.
EventID , , , "Z".
eventID, : _20120302T030000Z
Google Calendar. gdata , , eventid, Z.
:
1. ( " "
, .
2. .
SingleEvents(TRUE), FALSE "Rob" , .
:
function outputCalendarByDateRange($client, $startDate='2012-02-27',
$endDate='2012-03-03')
{
$gdataCal = new Zend_Gdata_Calendar($client);
$query = $gdataCal->newEventQuery();
$query->setUser('default');
$query->setVisibility('private');
$query->setProjection('full');
$query->setOrderby('starttime');
$query->setStartMin($startDate);
$query->setStartMax($endDate);
$query->setSingleEvents(FALSE);
$eventFeed = $gdataCal->getCalendarEventFeed($query);
foreach ($eventFeed as $event) {
echo "Title: " . $event->title->text . "<br />";
echo "Event ID: " . $event->id->text . "<br />";
foreach ($event->when as $when) {
echo "Start: " . $when->startTime . "<br />";
}
echo "<br />";
}
}