You are here

function getICalDate in Availability Calendars 7.5

Returns a date in the iCal date format.

Parameters

\Datetime $date:

Return value

string A date according tot he iCal date format

1 call to getICalDate()
availability-calendar-ical-vcalendar.tpl.php in theme/availability-calendar-ical-vcalendar.tpl.php

File

theme/availability_calendar_ical_util.php, line 57

Code

function getICalDate(DateTime $date = null) {
  $iCalFormat = 'Ymd';
  return $date ? $date
    ->format($iCalFormat) : gmdate($iCalFormat);
}