wiki/content/20201113123648-createfromimmutable.md

17 lines
339 B
Markdown

---
date: 2020-11-13
id: 984344e1-ee68-4475-b792-71f2a6e0b766
title: createFromImmutable()
---
# Description
Similar to [createFromInterface()](20201113123327-createfrominterface),
but this function creates a `DateTime` object from a `DateTimeImmutable`
one.
# Syntax
``` php
DateTime::createFromImmutable(new DateTimeImmutable())
```