DateTime::__construct
DateTime::diff
DateTime
PHP Manual

# DateTime::createFromFormat

(PHP 5 >= 5.3.0)

DateTime::createFromFormat — Returns new DateTime object formatted according to the specified format

### Descripción

public static DateTime DateTime::createFromFormat ( string `$format` , string `$time` [, DateTimeZone `$timezone` ] )

Returns new DateTime object formatted according to the specified format.

### Lista de parámetros

`format`

  Format accepted by date().

`time`

  String representing the time.

`timezone`

  Time zone.

### Valores retornados

Returns new DateTime instance.

DateTime::__construct
DateTime::diff
DateTime
PHP Manual