Coding standards
Security in ResourceSpace
Developer reference
Database
Action functions
Admin functions
Ajax functions
Annotation functions
API functions
Collections functions
Comment functions
Config functions
CSV export functions
Dash functions
Debug functions
Encryption functions
Facial recognition functions
File functions
General functions
Language functions
Log functions
Login functions
Message functions
Migration functions
Node functions
PDF functions
Plugin functions
Render functions
Reporting functions
Request functions
Research functions
Slideshow functions
Theme permission functions
User functions
Video functions
Database functions
Metadata functions
Resource functions
Search functions
Map functions
Job functions
Tab functions
Test functions

nicedate()

Description

Formats a MySQL ISO date

Always use the 'wordy' style from now on as this works better internationally.


@var string $date ISO format date which can be a BCE date (ie. with negative year -yyyy)
@var boolean $time When TRUE and full date is present then append the hh:mm time part if present
@var boolean $wordy When TRUE return month name, otherwise return month number
@var boolean $offset_tz Set to TRUE to offset based on time zone, FALSE otherwise

Parameters

ColumnTypeDefaultDescription
$date
$time false
$wordy true
$offset_tz false

Return

string Returns an empty string if date not set/invalid

This article was last updated 4th December 2024 08:35 Europe/London time based on the source file dated 28th November 2024 15:15 Europe/London time.