Oihana PHP

tomorrow.php

Table of Contents

Functions

tomorrow()  : DateTimeImmutable
Returns the start of the day following a reference date.

Functions

tomorrow()

Returns the start of the day following a reference date.

tomorrow([DateTimeInterface|null $now = null ]) : DateTimeImmutable

startOfDay( addDays( $now , 1 ) ) — always 00:00:00.000000 on the next calendar day, regardless of the time of day $now carries. The timezone of the returned value is the one carried by $now.

Parameters
$now : DateTimeInterface|null = null

The reference date. Defaults to the current date/time.

Tags
throws
DateMalformedStringException

Never thrown in practice (the modifier is always well-formed).

example
use function oihana\core\date\tomorrow;

tomorrow( new DateTimeImmutable( '2026-03-15 14:30:45' ) ) ; // 2026-03-16 00:00:00.000000
author

Marc Alcaraz (ekameleon)

since
1.2.0
Return values
DateTimeImmutable

The start of the day after $now.

On this page

Search results