function date_repeat_field_date_field_formatter_settings_form_alter

cis7 date_repeat_field.module date_repeat_field_date_field_formatter_settings_form_alter(&$form, &$form_state, $context)
cle7 date_repeat_field.module date_repeat_field_date_field_formatter_settings_form_alter(&$form, &$form_state, $context)
elmsmedia7 date_repeat_field.module date_repeat_field_date_field_formatter_settings_form_alter(&$form, &$form_state, $context)
icor7 date_repeat_field.module date_repeat_field_date_field_formatter_settings_form_alter(&$form, &$form_state, $context)
meedjum_blog7 date_repeat_field.module date_repeat_field_date_field_formatter_settings_form_alter(&$form, &$form_state, $context)
mooc7 date_repeat_field.module date_repeat_field_date_field_formatter_settings_form_alter(&$form, &$form_state, $context)

Implements hook_date_field_foramatter_settings_form_alter().

This hook lets us alter the field formatter settings form.

File

sites/all/modules/ulmus/date/date_repeat_field/date_repeat_field.module, line 672
Creates the option of Repeating date fields and manages Date fields that use the Date Repeat API.

Code

function date_repeat_field_date_field_formatter_settings_form_alter(&$form, &$form_state, $context) {

  $field = $context['field'];
  $instance = $context['instance'];
  $view_mode = $context['view_mode'];
  $display = $instance['display'][$view_mode];
  $formatter = $display['type'];
  $settings = $display['settings'];
  if ($formatter == 'date_default') {
    $form['show_repeat_rule'] = array(
      '#title' => t('Repeat rule:'),
      '#type' => 'select',
      '#options' => array(
        'show' => t('Show repeat rule'),
        'hide' => t('Hide repeat rule'),
      ),
      '#default_value' => $settings['show_repeat_rule'],
      '#access' => $field['settings']['repeat'],
      '#weight' => 5,
    );
  }
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.