-
Notifications
You must be signed in to change notification settings - Fork 0
cDateISO::__construct()
Rainer Stötter edited this page May 17, 2017
·
2 revisions
public \libdatephp\cDate libdatephp\cDate::__construct(mixed $m, mixed $d, integer $y)
- Namespace : libdatephp
- Class name: cDateISO
- This method is defined by libdatephp\cDate
The constructor for the cDate class
Example:
$p = new cDate( 11, 22, 2016 ); from month, day, year
$p = new cDate( '2017-02-28' ); from SQL string
$p = new cDate( '28.02.2017' ); from DMY string
$p = new cDate( '02-28-2017' ); from MDY string
$p = new cDate( ); a date with today's date
$dtm = new cDate( new cDate( 11, 22, 2016 ) ); a copy constructor
$dtm = new cDate( 200516 ); from a timestamp
- $m mixed - <p>can be an int as month or a timestamp or a cDate</p>
- $d mixed - <p>can be a date or an int as day or a cDate</p>
- $y integer - <p>the year of the first date</p>
\libdatephp\cDate
This wiki page is part of the documentation of the PHP class library libdatephp