summaryrefslogtreecommitdiffstats
path: root/user_guide_src/source/helpers/date_helper.rst
diff options
context:
space:
mode:
Diffstat (limited to 'user_guide_src/source/helpers/date_helper.rst')
-rw-r--r--user_guide_src/source/helpers/date_helper.rst32
1 files changed, 16 insertions, 16 deletions
diff --git a/user_guide_src/source/helpers/date_helper.rst b/user_guide_src/source/helpers/date_helper.rst
index dcff7a4e5..bed3b32a2 100644
--- a/user_guide_src/source/helpers/date_helper.rst
+++ b/user_guide_src/source/helpers/date_helper.rst
@@ -24,7 +24,7 @@ Available Functions
The following functions are available:
-.. function:: now([$timezone = NULL])
+.. php:function:: now([$timezone = NULL])
:param string $timezone: Timezone
:returns: UNIX timestamp
@@ -43,7 +43,7 @@ The following functions are available:
If a timezone is not provided, it will return ``time()`` based on the
**time_reference** setting.
-.. function:: mdate([$datestr = ''[, $time = '']])
+.. php:function:: mdate([$datestr = ''[, $time = '']])
:param string $datestr: Date string
:param int $time: UNIX timestamp
@@ -67,7 +67,7 @@ The following functions are available:
If a timestamp is not included in the second parameter the current time
will be used.
-.. function:: standard_date([$fmt = 'DATE_RFC822'[, $time = NULL]])
+.. php:function:: standard_date([$fmt = 'DATE_RFC822'[, $time = NULL]])
:param string $fmt: Date format
:param int $time: UNIX timestamp
@@ -106,7 +106,7 @@ The following functions are available:
DATE_W3C W3C 2005-08-14T16:13:03+0000
=============== ======================= ======================================
-.. function:: local_to_gmt([$time = ''])
+.. php:function:: local_to_gmt([$time = ''])
:param int $time: UNIX timestamp
:returns: UNIX timestamp
@@ -118,7 +118,7 @@ The following functions are available:
$gmt = local_to_gmt(time());
-.. function:: gmt_to_local([$time = ''[, $timezone = 'UTC'[, $dst = FALSE]]])
+.. php:function:: gmt_to_local([$time = ''[, $timezone = 'UTC'[, $dst = FALSE]]])
:param int $time: UNIX timestamp
:param string $timezone: Timezone
@@ -140,7 +140,7 @@ The following functions are available:
.. note:: For a list of timezones see the reference at the bottom of this page.
-.. function:: mysql_to_unix([$time = ''])
+.. php:function:: mysql_to_unix([$time = ''])
:param string $time: MySQL timestamp
:returns: UNIX timestamp
@@ -152,7 +152,7 @@ The following functions are available:
$unix = mysql_to_unix('20061124092345');
-.. function:: unix_to_human([$time = ''[, $seconds = FALSE[, $fmt = 'us']]])
+.. php:function:: unix_to_human([$time = ''[, $seconds = FALSE[, $fmt = 'us']]])
:param int $time: UNIX timestamp
:param bool $seconds: Whether to show seconds
@@ -179,13 +179,13 @@ The following functions are available:
echo unix_to_human($now, TRUE, 'us'); // U.S. time with seconds
echo unix_to_human($now, TRUE, 'eu'); // Euro time with seconds
-.. function:: human_to_unix([$datestr = ''])
+.. php:function:: human_to_unix([$datestr = ''])
:param int $datestr: Date string
:returns: UNIX timestamp or FALSE on failure
:rtype: int
- The opposite of the :func:`unix_to_time()` function. Takes a "human"
+ The opposite of the :php:func:`unix_to_time()` function. Takes a "human"
time as input and returns it as a UNIX timestamp. This is useful if you
accept "human" formatted dates submitted via a form. Returns boolean FALSE
date string passed to it is not formatted as indicated above.
@@ -196,7 +196,7 @@ The following functions are available:
$human = unix_to_human($now);
$unix = human_to_unix($human);
-.. function:: nice_date([$bad_date = ''[, $format = FALSE]])
+.. php:function:: nice_date([$bad_date = ''[, $format = FALSE]])
:param int $bad_date: The terribly formatted date-like string
:param string $format: Date format to return (same as PHP's ``date()`` function)
@@ -220,7 +220,7 @@ The following functions are available:
// Should Produce: 2001-09-11
$better_date = nice_date($bad_date, 'Y-m-d');
-.. function:: timespan([$seconds = 1[, $time = ''[, $units = '']]])
+.. php:function:: timespan([$seconds = 1[, $time = ''[, $units = '']]])
:param int $seconds: Number of seconds
:param string $time: UNIX timestamp
@@ -252,7 +252,7 @@ The following functions are available:
.. note:: The text generated by this function is found in the following language
file: `language/<your_lang>/date_lang.php`
-.. function:: days_in_month([$month = 0[, $year = '']])
+.. php:function:: days_in_month([$month = 0[, $year = '']])
:param int $month: a numeric month
:param int $year: a numeric year
@@ -271,7 +271,7 @@ The following functions are available:
.. note:: This function will alias the native ``cal_days_in_month()``, if
it is available.
-.. function:: date_range([$unix_start = ''[, $mixed = ''[, $is_unix = TRUE[, $format = 'Y-m-d']]]])
+.. php:function:: date_range([$unix_start = ''[, $mixed = ''[, $is_unix = TRUE[, $format = 'Y-m-d']]]])
:param int $unix_start: UNIX timestamp of the range start date
:param int $mixed: UNIX timestamp of the range end date or interval in days
@@ -291,7 +291,7 @@ The following functions are available:
echo $date."\n";
}
-.. function:: timezones([$tz = ''])
+.. php:function:: timezones([$tz = ''])
:param string $tz: A numeric timezone
:returns: Hour difference from UTC
@@ -306,9 +306,9 @@ The following functions are available:
echo timezones('UM5');
- This function is useful when used with :func:`timezone_menu()`.
+ This function is useful when used with :php:func:`timezone_menu()`.
-.. function:: timezone_menu([$default = 'UTC'[, $class = ''[, $name = 'timezones'[, $attributes = '']]]])
+.. php:function:: timezone_menu([$default = 'UTC'[, $class = ''[, $name = 'timezones'[, $attributes = '']]]])
:param string $default: Timezone
:param string $class: Class name