Calling all Drupal developers!
Help us get this on the first page of Digg. DIGG NOW!
Help us get this on the first page of Digg. DIGG NOW!
1.64.2.5.2.5 (checked in on 2008/06/11 at 11:15:52 by karens)
This module will make the date API available to other modules. Designed to provide a light but flexible assortment of functions and constants, with more functionality in additional files that are not loaded unless other modules specifically include them.
| Name | Description |
|---|---|
| date_ampm | An array of am and pm options. |
| date_api_elements | Implementation of hook_elements(). |
| date_api_init | Implementation of hook_init(). |
| date_api_set_db_timezone | Wrapper around date handler setting for timezone. |
| date_api_simpletest | Implementation of hook_simpletest(). |
| date_api_theme | |
| date_api_views_fetch_fields | Wrapper function to make sure this function will always work. |
| date_array | Create an array of values from a date object. Structured like the results of getdate() but not limited to the 32-bit signed range. |
| date_convert | Date conversion helper function. |
| date_days | An array of days. |
| date_days_in_month | Identify the number of days in a month for a date. |
| date_days_in_year | Identify the number of days in a year for a date. |
| date_day_of_week | Returns day of week for a given date (0 = Sunday). |
| date_day_of_week_name | Returns translated name of the day of week for a given date. |
| date_default_timezone | A timezone object for the default timezone. |
| date_default_timezone_name | Return a timezone name to use as a default. |
| date_difference | Compute difference between two days using a given measure. |
| date_format_date | Reworked from Drupal's format_date function to handle pre-1970 and post-2038 dates and accept a date object instead of a timestamp as input. |
| date_format_interval | An override for interval formatting that adds past and future context |
| date_format_order | Convert a format to an ordered array of granularity parts. |
| date_format_patterns | Array of regex replacement strings for date format elements. Used to allow input in custom formats. Based on work done for the Date module by Yves Chedemois (yched). |
| date_fuzzy_datetime | Create valid datetime value from incomplete ISO dates or arrays. |
| date_granularity_names | Array of granularity options and their labels |
| date_has_time | Function to figure out if any time data is to be collected or displayed. |
| date_hours | An array of hours. |
| date_iso_array | Create an array of date parts from an ISO date. |
| date_iso_weeks_in_year | Identify the number of ISO weeks in a year for a date. |
| date_is_valid | Functions to test the validity of a date in various formats. Has special case for ISO dates and arrays which can be missing month and day and still be valid. |
| date_limit_format | Rewrite a format string so it only inludes elements from a specified granularity array. |
| date_limit_value | Recalculate a date so it only includes elements from a granularity array. Helps prevent errors when unwanted values round up and ensures that unwanted date part values don't get stored in the database. |
| date_long_formats | An array of long date formats. |
| date_make_date | Convert a date of any type or an array of date parts into a valid date object. |
| date_medium_formats | An array of medium date formats. |
| date_minutes | An array of minutes. |
| date_month_names | A translated array of month names |
| date_month_names_abbr | A translated array of month name abbreviations |
| date_month_names_untranslated | An untranslated array of month names |
| date_nongranularity | An difference array of granularity elements that are NOT in the granularity array. Used by functions that strip unwanted granularity elements out of formats and values. |
| date_now | A date object for the current time. |
| date_pad | Helper function to left pad date parts with zeros. Provided because this is needed so often with dates. |
| date_part_extract | Extract integer value of any date part from any type of date. |
| date_seconds | An array of seconds. |
| date_short_formats | An array of short date formats. |
| date_t | A version of the t() function for date parts that need translation. |
| date_timezone_abbr | An array of timezone abbreviations that the system allows. Cache an array of just the abbreviation names because the whole timezone_abbreviations_list is huge so we don't want to get it more than necessary. |
| date_timezone_names | A translated array of timezone names. Cache the untranslated array, make the translated array a static variable. |
| date_type_format | Helper function for getting the format string for a date type. |
| date_week | The calendar week number for a date. |
| date_weeks_in_year | The number of calendar weeks in a year. |
| date_week_days | A translated array of week days |
| date_week_days_abbr | An translated array of week day abbreviations. |
| date_week_days_ordered | Order weekdays Correct weekdays array so first day in array matches the first day of the week. Use to create things like calendar headers. |
| date_week_days_untranslated | An untranslated array of week days |
| date_week_range | Start and end dates for a calendar week, adjusted to use the chosen first day of week for this site. |
| date_years | An array of years. |