You are here

function _datex_field_calendar in Datex 7.2

Find suitable calendar for field.

5 calls to _datex_field_calendar()
datex_date_formatter_dates_alter in ./datex_date.inc
Implemetns hook_date_formatter_dates_alter().
datex_date_select_process_alter in ./datex_date.inc
Handles date field.
datex_popup_date_popup_process_alter in datex_popup/datex_popup.module
Implements hook_date_popup_process_alter().
_datex_element_validate_callback in ./datex_date.inc
Form element validation callback.
_datex_popup_element_validate_callback in datex_popup/datex_popup.module
Form element validation callback.

File

./datex_date.inc, line 36
Provides Jalali support for date module.

Code

function _datex_field_calendar($granularities, $schema = 'default', $tz = NULL) {
  if ($schema == 'disabled') {
    return FALSE;
  }
  $locale = _datex_language_calendar(NULL, NULL, $schema);
  if (!$locale) {
    return FALSE;
  }
  if (!_datex_date_granularities_supported($granularities)) {
    return FALSE;
  }
  return datex_factory($locale, NULL, NULL, $tz, _datex_cfg('useintl'));
}