endOfDay.php
Table of Contents
Functions
- endOfDay() : DateTimeImmutable
- Returns the last representable instant of the day containing a date.
Functions
endOfDay()
Returns the last representable instant of the day containing a date.
endOfDay(DateTimeInterface $date) : DateTimeImmutable
A new DateTimeImmutable is returned, its date unchanged and its time set to
23:59:59.999999 (microseconds included) ; the source date is never modified. The
timezone of the returned value is the one carried by $date.
Parameters
- $date : DateTimeInterface
-
The source date.
Tags
Return values
DateTimeImmutable —A new immutable date, at the end of the same day.