You are here

function cmfcCalendarV1Arabic::infoArrayToTimestamp in Calendar Systems 6

Same name and namespace in other branches
  1. 8 calendar/v1/calendarSystems/arabic.class.inc.php \cmfcCalendarV1Arabic::infoArrayToTimestamp()
  2. 8.2 calendar/v1/calendarSystems/arabic.class.inc.php \cmfcCalendarV1Arabic::infoArrayToTimestamp()
  3. 6.3 calendar/v1/calendarSystems/arabic.class.inc.php \cmfcCalendarV1Arabic::infoArrayToTimestamp()
  4. 7.3 calendar/v1/calendarSystems/arabic.class.inc.php \cmfcCalendarV1Arabic::infoArrayToTimestamp()
  5. 7 calendar/v1/calendarSystems/arabic.class.inc.php \cmfcCalendarV1Arabic::infoArrayToTimestamp()
  6. 7.2 calendar/v1/calendarSystems/arabic.class.inc.php \cmfcCalendarV1Arabic::infoArrayToTimestamp()

* Islamic Calendar *

Overrides cmfcCalendarV1::infoArrayToTimestamp

See also

v1/cmfcCalendarV1#infoArrayToTimestamp()

1 call to cmfcCalendarV1Arabic::infoArrayToTimestamp()
cmfcCalendarV1Arabic::timestampToInfoArray in calendar/v1/calendarSystems/arabic.class.inc.php

File

calendar/v1/calendarSystems/arabic.class.inc.php, line 140

Class

cmfcCalendarV1Arabic

Code

function infoArrayToTimestamp($arr) {
  list($gy, $gm, $gd) = $this
    ->toGregorian($arr['year'], $arr['month'], $arr['day']);
  if (!isset($arr['hour'])) {
    $arr['hour'] = $this
      ->phpDate('H');
  }
  if (!isset($arr['minute'])) {
    $arr['minute'] = $this
      ->phpDate('i');
  }
  if (!isset($arr['second'])) {
    $arr['second'] = $this
      ->phpDate('s');
  }
  return strtotime("{$gy}-{$gm}-{$gd}" . ' ' . $arr['hour'] . ':' . $arr['minute'] . ':' . $arr['second']);
}