date_parse function returns associative array with detailed information about given date. It returns information about the date on success, or FALSE on failure. An error message will display if date format faces any error.
Description on Date Parse Format in PHP
array date_parse ( string $date )
Parameters of date parse class PHPdate - Date in format accepted by strtotime()
<?php
print_r(date_parse("2009-04-28 07:45:20.5"));
?>
The above example will output:
Array
(
[year] => 2009
[month] => 04
[day] => 28
[hour] => 07
[minute] => 45
[second] => 20
[fraction] => 0.5
[warning_count] => 0
[warnings] => Array()
[error_count] => 0
[errors] => Array()
[is_localtime] =>
)
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.