I'm coding a swift clean php implementation of the calendar data api.
For my taste the Zend one is much to big. At this moment the
interaction with the Calendar Data API is working correctly, so that's
not the problem.
At this moment I'm using my implementation to synchronize an existing
webbased calendar to the google calendar. I'm facing problems making
it work correctly because it's not possible to undo changes at the
google calendar or am
I missing something?
Code says more then a thousand words ;)
try{
/* start transaction */
$this->db->startTransaction();
$auth->lastPush = $time;
$auth->lastPushID = $id;
/* save details of auth to database */
$auth->save();
if($this->googleID == null){
$this->googleID = GoogleCalendarSynchronizer::AddEvent($auth,
$this);
} else {
$this->googleID = GoogleCalendarSynchronizer::ChangeEvent($auth,
$this);
}
/* THIS is the point where the code breaks. The event has already
* been written to or changed in the google calendar but when the
* following database query fails then the event remains added
* to the online schedule but isn't marked as such in the local
database */
/* save the new or changed google ID to the database */
$this->save();
/* commit tranaction */
$this->db->commitTransaction();
} catch(Exception $e){
/* rollback */
$this->db->rollbackTransaction();
throw $e;
}
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Calendar Data API" group.
To post to this group, send email to
[email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-calendar-help-dataapi?hl=en
-~----------~----~----~----~------~----~------~--~---