本文整理匯總了PHP中OC_Calendar_Object::getCategoryOptions方法的典型用法代碼示例。如果您正苦於以下問題:PHP OC_Calendar_Object::getCategoryOptions方法的具體用法?PHP OC_Calendar_Object::getCategoryOptions怎麽用?PHP OC_Calendar_Object::getCategoryOptions使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類OC_Calendar_Object
的用法示例。
在下文中一共展示了OC_Calendar_Object::getCategoryOptions方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: OC_L10N
<?php
/**
* Copyright (c) 2011 Bart Visscher <bartv@thisnet.nl>
* This file is licensed under the Affero General Public License version 3 or
* later.
* See the COPYING-README file.
*/
require_once '../../../lib/base.php';
$l10n = new OC_L10N('calendar');
if (!OC_USER::isLoggedIn()) {
die('<script type="text/javascript">document.location = oc_webroot;</script>');
}
OC_JSON::checkAppEnabled('calendar');
$calendar_options = OC_Calendar_Calendar::allCalendars(OC_User::getUser());
$category_options = OC_Calendar_Object::getCategoryOptions($l10n);
$repeat_options = OC_Calendar_Object::getRepeatOptions($l10n);
$id = $_GET['id'];
$data = OC_Calendar_Object::find($id);
$calendar = OC_Calendar_Calendar::findCalendar($data['calendarid']);
if ($calendar['userid'] != OC_User::getUser()) {
echo $l10n->t('Wrong calendar');
exit;
}
$object = Sabre_VObject_Reader::read($data['calendardata']);
$vevent = $object->VEVENT;
$dtstart = $vevent->DTSTART;
$dtend = OC_Calendar_Object::getDTEndFromVEvent($vevent);
switch ($dtstart->getDateType()) {
case Sabre_VObject_Element_DateTime::LOCALTZ:
case Sabre_VObject_Element_DateTime::LOCAL:
開發者ID:Teino1978-Corp,項目名稱:Teino1978-Corp-owncloud_.htaccess-,代碼行數:31,代碼來源:owncloud_apps_calendar_ajax_editeventform.php