You are here

function date_repeat_dow_options in Date 8

Same name and namespace in other branches
  1. 5.2 date_repeat/date_repeat.module \date_repeat_dow_options()
  2. 6.2 date_repeat/date_repeat.module \date_repeat_dow_options()
  3. 6 date_repeat/date_repeat.module \date_repeat_dow_options()
  4. 7.3 date_repeat/date_repeat.module \date_repeat_dow_options()
  5. 7 date_repeat/date_repeat.module \date_repeat_dow_options()
  6. 7.2 date_repeat/date_repeat.module \date_repeat_dow_options()

Helper function for BYDAY options.

Creates options like -1SU and 2TU

File

date_repeat/date_repeat.module, line 148
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 date_repeat_dow_options() {
  $options = array();
  foreach (date_repeat_dow_count_options() as $count_key => $count_value) {
    foreach (date_repeat_dow_day_options() as $dow_key => $dow_value) {
      $options[$count_key . $dow_key] = $count_value . ' ' . $dow_value;
    }
  }
  return $options;
}