You are here

function cmfcCalendarV1::setTimeZoneOffset in Calendar Systems 8.2

Same name and namespace in other branches
  1. 8 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::setTimeZoneOffset()
  2. 5 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::setTimeZoneOffset()
  3. 6.3 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::setTimeZoneOffset()
  4. 6 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::setTimeZoneOffset()
  5. 7.3 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::setTimeZoneOffset()
  6. 7 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::setTimeZoneOffset()
  7. 7.2 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::setTimeZoneOffset()
1 call to cmfcCalendarV1::setTimeZoneOffset()
cmfcCalendarV1::setOption in calendar/v1/calendarV1.class.inc.php
* @NOTICE child classed definition should apply the byReference version of function *

File

calendar/v1/calendarV1.class.inc.php, line 76

Class

cmfcCalendarV1

Code

function setTimeZoneOffset($offset) {
  if (!empty($offset) && is_string($offset)) {
    list($hour, $minute) = explode(':', $offset);
    $offset = abs($hour) * 60 * 60 + $minute * 60;
    if ($hour < 0) {
      $offset = $offset * -1;
    }
  }
  $this->_timeZoneInfo['offset'] = $offset;
}