You are here

function INTERVAL_options in Date 7

Same name and namespace in other branches
  1. 5.2 date_repeat/date_repeat.module \INTERVAL_options()
  2. 6.2 date_repeat/date_repeat.module \INTERVAL_options()
  3. 6 date_repeat/date_repeat.module \INTERVAL_options()
3 calls to INTERVAL_options()
date_devel_generate in ./date.devel_generate.inc
Implementation of Devel module's hook_content_generate().
date_repeat_rrule_description in date_repeat/date_repeat.module
Build a description of an iCal rule.
_date_repeat_rrule_process in date_repeat/date_repeat_form.inc
Generate the repeat setting form.

File

date_repeat/date_repeat.module, line 60
This module creates a form element that allows users to select repeat rules for a date, and reworks the result into an iCal RRULE string that can be stored in the database.

Code

function INTERVAL_options() {
  $options = array(
    0 => t('-- Frequency'),
    1 => t('Every', array(), array(
      'context' => 'date_order',
    )),
  );
  for ($i = 2; $i < 367; $i++) {
    $options[$i] = t('Every @number', array(
      '@number' => $i,
    ));
  }
  return $options;
}