1 date.inc date_week_days($required = FALSE)

Returns a translated array of week names.

Parameters

bool $required: (optional) If FALSE, the returned array will include a blank value. Defaults to FALSE.

Return value

array: An array of week day names

File

core/includes/date.inc, line 181
Date API functions.

Code

function date_week_days($required = FALSE) {
  $weekdays = array();
  foreach (date_week_days_untranslated() as $key => $day) {
    $weekdays[$key] = t($day, array(), array('context' => ''));
  }
  $none = array('' => '');
  return !$required ? $none + $weekdays : $weekdays;
}