Search Results

  1. DateTimeImmutable::setTimestamp (PHP 5 >= 5.5.0, PHP 7, PHP 8) DateTimeImmutable::setTimestamp — Sets the date and time based on a Unix timestamp

    • createFromMutable

      DateTimeImmutable::createFromMutable (PHP 5 >= 5.6.0, PHP...

    • getLastErrors

      DateTimeImmutable::getLastErrors (PHP 5 >= 5.5.0, PHP 7,...

    • setISODate

      Returns a new DateTimeImmutable object with the date set...

    • setDate

      Returns a new DateTimeImmutable object with the current date...

    • Sub

      DateTimeImmutable::add () - Returns a new object, with added...

    • createFromFormat

      Returns a new DateTimeImmutable object representing the date...

    • Modify

      DateTimeImmutable::modify (PHP 5 >= 5.5.0, PHP 7, PHP 8)...

  2. DateTimeImmutable::setISODate — Sets the ISO date DateTimeImmutable::setTime — Sets the time DateTimeImmutable::setTimestamp — Sets the date and time based on a Unix timestamp DateTimeImmutable::setTimezone — Sets the time zone DateTimeImmutable::sub — Subtracts an amount of days, months, years, hours, minutes and seconds

  3. Assigne la date et l'heure à l'aide d'un horodatage Unix. Comme DateTimeImmutable:: setTimestamp () mais fonctionne avec DateTime. La version procédurale prend un objet DateTime comme premier argument.

  4. Calling setTimestamp on an already instantiated method On DateTime and DateTimeImmutable objects, the setTimestamp method accepts integer UNIX timestamp values. This approach also has the slight disadvantage of the first instantiation with the given/current time that get overridden from the setTimestamp call.

  5. Oct 9, 2021 · The whole point of DateTimeImmutable as opposed to DateTime is that it's immutable - it can't be changed once created. If you call modify() you return a new object, but don't modify the existing one.

  6. DateTimeImmutable::add DateTimeImmutable::__construct DateTimeImmutable::createFromFormat DateTimeImmutable::createFromInterface DateTimeImmutable::createFromMutable DateTimeImmutable::getLastErrors DateTimeImmutable::modify DateTimeImmutable::setDate DateTimeImmutable::setISODate DateTimeImmutable::__set_state DateTimeImmutable::setTimestamp

  7. People also ask

  8. Simple usage example of `DateTimeImmutable::setTimestamp ()`. The DateTimeImmutable::setTimestamp () function sets the date and time of a DateTimeImmutable object based on a Unix timestamp. It updates the object with the new date and time values.

  1. People also search for