定制 rb-cohen/ical-php 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

rb-cohen/ical-php

最新稳定版本:1.0.3

Composer 安装命令:

composer require rb-cohen/ical-php

包简介

Generate an iCal file by providing event objects

README 文档

README

Generate an iCal file by providing event objects

Example

<?php

use Ical\Feed;
use Ical\Component\Calendar;
use Ical\Component\Event;

// One feed (i.e. URL) can host more than one caldenar, lets create a feed
$feed = new Feed();

// This calendar will contain our events
$calendar = new Calendar('ical-example//v1');

$event = new Event('uid-1@example');
$event->created(new DateTime('2015-01-01'));
$event->lastModified(new DateTime('2015-01-05'));
$event->between(new DateTime('2015-04-01'), new DateTime('2015-04-01'));
$event->summary('Example of an event');
$event->allDay(true);

// Add this event to the calendar
$calendar->addEvent($event);

// Add the calendar to the feed
$feed->addCalendar($calendar);

// Output the feed with appropriate HTTP header
$feed->output();
exit;

统计信息

  • 总下载量: 1.06k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 2
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-02-09