0

このコードを使用して、Google カレンダーにカレンダーを追加したいと考えています。

function addCalendar($client, $nomeInsegnamento, $codiceInsegnamento){
    $calendar = new Calendar();
    $calendar->setSummary($nomeInsegnamento." - ".$codiceInsegnamento);
    $calendar->setTimeZone('Europe/Rome');
    return $client -> calendars -> insert($calendar);
}

PHP用のGoogle APIライブラリをインポートしました

require_once '../src/Google_Client.php';
require_once '../src/contrib/Google_CalendarService.php';

しかし、常にこのエラーが発生します

Fatal error: Class 'Calendar' not found in D:\Programmi\EasyPHP-DevServer-13.1VC9\data\localweb\projects\GCE\prova.php on line 182
4

1 に答える 1

0

にはそのようなクラスはありませCalendarGoogle_CalendarService.php: https://code.google.com/p/google-api-php-client/source/browse/trunk/src/contrib/Google_CalendarService.php

あなたはおそらくこの答えをチェックアウトしたいと思うでしょう

于 2013-06-08T07:30:15.663 に答える