phpmailer-php5/extras/EasyPeasyICS.php
public function addEvent($start, $end, $summary = '', $description = '', $url = '', $uid = '')
    {
        if (empty($uid)) {
            $uid = md5(uniqid(mt_rand(), true)) . '@EasyPeasyICS';
        }
        $event = array(
            'start' => gmdate('Ymd', $start) . 'T' . gmdate('His', $start) . 'Z',
            'end' => gmdate('Ymd', $end) . 'T' . gmdate('His', $end) . 'Z',
            'summary' => $summary,
            'description' => $description,
            'url' => $url,
            'uid' => $uid
        );
        $this->events[] = $event;
        return $event;
    }
public function addEvent($start, $end, $summary = '', $description = '', $url = '', $uid = '')
    {
        if (empty($uid)) {
            $uid = md5(uniqid(mt_rand(), true)) . '@EasyPeasyICS';
        }
        $event = array(
            'start' => gmdate('Ymd', $start) . 'T' . gmdate('His', $start) . 'Z',
            'end' => gmdate('Ymd', $end) . 'T' . gmdate('His', $end) . 'Z',
            'summary' => $summary,
            'description' => $description,
            'url' => $url,
            'uid' => $uid
        );
        $this->events[] = $event;
        return $event;
    }
public function addEvent ( $ start , $ end , $ summary = '' , $ description = '' , $ url = '' , $ uid = '' ) { if ( empty ( $ uid ) ) { $ uid = md5 ( uniqid ( mt_rand ( ) , true ) ) . '@EasyPeasyICS' ; } $ event = array ( 'start' => gmdate ( 'Ymd' , $ start ) . 'T' . gmdate ( 'His' , $ start ) . 'Z' , 'end' => gmdate ( 'Ymd' , $ end ) . 'T' . gmdate ( 'His' , $ end ) . 'Z' , 'summary' => $ summary , 'description' => $ description , 'url' => $ url , 'uid' => $ uid ) ; $ this -> events [ ] = $ event ; return $ event ; }
Add an event to this calendar.
@param string $start The start date and time as a unix timestamp
@param string $end The end date and time as a unix timestamp
@param string $summary A summary or title for the event
@param string $description A description of the event
@param string $url A URL for the event
@param string $uid A unique identifier for the event - generated automatically if not provided
@return array An array of event details, including any generated UID
Add an event to this calendar .