Skip navigation
Help

Formatting

  1. drupal
    1. 6 drupal/includes/common.inc
    2. 7 drupal/includes/common.inc

Functions to format numbers, strings, dates, etc.

Functions & methods

NameDescription
date_iso8601Returns an ISO8601 formatted date based on the given date.
format_dateFormats a date, using a date type or a custom date format string.
format_intervalFormat a time interval with the requested granularity.
format_pluralFormat a string containing a count of items.
format_rss_channelFormats an RSS channel.
format_rss_itemFormat a single RSS item.
format_sizeGenerate a string representation for the given byte count.
format_usernameFormat a username.
format_xml_elementsFormat XML elements.
parse_sizeParse a given byte count.
_format_date_callbackCallback function for preg_replace_callback().

File

drupal/includes/common.inc, line 1569
Common functions that many Drupal modules will need to reference.