Core Function
View Source on Trac ↗ wp_date()
wp_date( mixed $format, mixed $timestamp = null, mixed $timezone = null ) Retrieves the date, in localized format.
Parameters 2 required
| Name / Type | Description |
|---|---|
| $format string | PHP date format. Required |
| $timestamp int | Optional. Unix timestamp. Defaults to current time. |
| DateTimeZone | $timezone Optional. Timezone to output result in. Defaults to timezone from site settings. Required |
Return Value
((string)
| false) The date, translated if locale specifies it. False on invalid timestamp input.
Function Information
Since Version
5.3.0
Source File
wp-includes/functions.php
Advertisement