Download the PHP package graceas/php-ics-reader without Composer

On this page you can find all versions of the php package graceas/php-ics-reader. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package php-ics-reader

IcsReader

This class for parse iCal-file (*.ics).

Installation

Through composer:

"require": {
    ...
    "graceas/php-ics-reader": "v1.0"
    ...
}

Usage

Code:

<?php
include 'vendor/autoload.php';

use IcsReader\IcsReader;

$icsContent = <<<EOF
BEGIN:VCALENDAR
PRODID:-//Google Inc//Google Calendar 70.9054//EN
VERSION:2.0
CALSCALE:GREGORIAN
METHOD:PUBLISH
X-WR-CALNAME:TestCalendar
X-WR-TIMEZONE:Europe/Berlin
X-WR-CALDESC:Test Google Calendar
BEGIN:VEVENT
DTSTART:20110105T090000Z
DTEND:20110107T173000Z
DTSTAMP:20110121T195741Z
UID:[email protected]
CREATED:20110121T195616Z
DESCRIPTION:This is a short description\nwith a new line. Some "special" 's
 igns' may be <interesting>\, too.
LAST-MODIFIED:20110121T195729Z
LOCATION:Kansas
SEQUENCE:2
STATUS:CONFIRMED
SUMMARY:My Holidays
TRANSP:TRANSPARENT
END:VEVENT
BEGIN:VEVENT
DTSTART;VALUE=DATE:20110112
DTEND;VALUE=DATE:20110116
DTSTAMP:20110121T195741Z
UID:[email protected]
CREATED:20110119T142901Z
DESCRIPTION:Project xyz Review Meeting Minutes\n
 Agenda\n1. Review of project version 1.0 requirements.\n2.
 Definition
 of project processes.\n3. Review of project schedule.\n
 Participants: John Smith, Jane Doe, Jim Dandy\n-It was
  decided that the requirements need to be signed off by
  product marketing.\n-Project processes were accepted.\n
 -Project schedule needs to account for scheduled holidays
  and employee vacation time. Check with HR for specific
  dates.\n-New schedule will be distributed by Friday.\n-
 Next weeks meeting is cancelled. No meeting until 3/23.
LAST-MODIFIED:20110119T152216Z
LOCATION:
SEQUENCE:2
STATUS:CONFIRMED
SUMMARY:test 11
TRANSP:TRANSPARENT
END:VEVENT
BEGIN:VEVENT
DTSTART;VALUE=DATE:20110119
DTEND;VALUE=DATE:20110120
DTSTAMP:20110121T195741Z
UID:[email protected]
CREATED:20110119T141923Z
DESCRIPTION:
LAST-MODIFIED:20110119T141923Z
LOCATION:
SEQUENCE:0
STATUS:CONFIRMED
SUMMARY:test 6
TRANSP:TRANSPARENT
END:VEVENT
BEGIN:VEVENT
DTSTART;VALUE=DATE:20110119
DTEND;VALUE=DATE:20110120
DTSTAMP:20110121T195741Z
UID:[email protected]
CREATED:20110119T141913Z
DESCRIPTION:
LAST-MODIFIED:20110119T141913Z
LOCATION:
SEQUENCE:0
STATUS:CONFIRMED
SUMMARY:test 4
TRANSP:TRANSPARENT
END:VEVENT
BEGIN:VEVENT
DTSTART;VALUE=DATE:20400201
DTEND;VALUE=DATE:20400202
DTSTAMP:20400101T195741Z
UID:[email protected]
CREATED:20400101T141901Z
DESCRIPTION:
LAST-MODIFIED:20400101T141901Z
LOCATION:
SEQUENCE:0
STATUS:CONFIRMED
SUMMARY:Year 2038 problem test
TRANSP:TRANSPARENT
END:VEVENT
BEGIN:VEVENT
DTSTART;VALUE=DATE:19410512
DTEND;VALUE=DATE:19410512
DTSTAMP:19410512T195741Z
UID:[email protected]
CREATED:20400101T141901Z
DESCRIPTION:
LAST-MODIFIED:20400101T141901Z
LOCATION:
SEQUENCE:0
STATUS:CONFIRMED
SUMMARY:Before 1970-Test: John Doe invents the Z3, the first digital Computer
TRANSP:TRANSPARENT
END:VEVENT
END:VCALENDAR
EOF;

$reader = new IcsReader();
$ics    = $reader->parse($icsContent);

print_r($ics->getCalendar());
print_r($ics->getEvents());

Example output:

Array
(
    [0] => Array
        (
            [DTSTART] => 20110105T090000Z
            [DTEND] => 20110107T173000Z
            [DTSTAMP] => 20110121T195741Z
            [UID] => [email protected]
            [CREATED] => 20110121T195616Z
            [DESCRIPTION] => This is a short descriptionwith a new line. Some "special" 'signs' may be <interesting>\, too.
            [LAST-MODIFIED] => 20110121T195729Z
            [LOCATION] => Kansas
            [SEQUENCE] => 2
            [STATUS] => CONFIRMED
            [SUMMARY] => My Holidays
            [TRANSP] => TRANSPARENT
        )

    [1] => Array
        (
            [DTSTART] => 20110112
            [DTEND] => 20110116
            [DTSTAMP] => 20110121T195741Z
            [UID] => [email protected]
            [CREATED] => 20110119T142901Z
            [DESCRIPTION] => Project xyz Review Meeting MinutesAgenda1. Review of project version 1.0 requirements.2.Definitionof project processes.3. Review of project schedule.
            [Participants] =>  John Smith, Jane Doe, Jim Dandy-It wasdecided that the requirements need to be signed off byproduct marketing.-Project processes were accepted.-Project schedule needs to account for scheduled holidaysand employee vacation time. Check with HR for specificdates.-New schedule will be distributed by Friday.-Next weeks meeting is cancelled. No meeting until 3/23.
            [LAST-MODIFIED] => 20110119T152216Z
            [LOCATION] => 
            [SEQUENCE] => 2
            [STATUS] => CONFIRMED
            [SUMMARY] => test 11
            [TRANSP] => TRANSPARENT
        )

    [2] => Array
        (
            [DTSTART] => 20110119
            [DTEND] => 20110120
            [DTSTAMP] => 20110121T195741Z
            [UID] => [email protected]
            [CREATED] => 20110119T141923Z
            [DESCRIPTION] => 
            [LAST-MODIFIED] => 20110119T141923Z
            [LOCATION] => 
            [SEQUENCE] => 0
            [STATUS] => CONFIRMED
            [SUMMARY] => test 6
            [TRANSP] => TRANSPARENT
        )

    [3] => Array
        (
            [DTSTART] => 20110119
            [DTEND] => 20110120
            [DTSTAMP] => 20110121T195741Z
            [UID] => [email protected]
            [CREATED] => 20110119T141913Z
            [DESCRIPTION] => 
            [LAST-MODIFIED] => 20110119T141913Z
            [LOCATION] => 
            [SEQUENCE] => 0
            [STATUS] => CONFIRMED
            [SUMMARY] => test 4
            [TRANSP] => TRANSPARENT
        )

    [4] => Array
        (
            [DTSTART] => 20400201
            [DTEND] => 20400202
            [DTSTAMP] => 20400101T195741Z
            [UID] => [email protected]
            [CREATED] => 20400101T141901Z
            [DESCRIPTION] => 
            [LAST-MODIFIED] => 20400101T141901Z
            [LOCATION] => 
            [SEQUENCE] => 0
            [STATUS] => CONFIRMED
            [SUMMARY] => Year 2038 problem test
            [TRANSP] => TRANSPARENT
        )

    [5] => Array
        (
            [DTSTART] => 19410512
            [DTEND] => 19410512
            [DTSTAMP] => 19410512T195741Z
            [UID] => [email protected]
            [CREATED] => 20400101T141901Z
            [DESCRIPTION] => 
            [LAST-MODIFIED] => 20400101T141901Z
            [LOCATION] => 
            [SEQUENCE] => 0
            [STATUS] => CONFIRMED
            [SUMMARY] => Before 1970-Test: John Doe invents the Z3, the first digital Computer
            [TRANSP] => TRANSPARENT
        )

)

All versions of php-ics-reader with dependencies

PHP Build Version
Package Version
Requires php Version >=5.6
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package graceas/php-ics-reader contains the following files

Loading the files please wait ....