web 2.0

How to use PHP & Get Date and date_parse()

How to use PHP & Get Date and date_parse() This function will be using PHP and  using function date_parse()

ShotDev Focus:
- PHP & date_parse()

Example

php_date_parse.php


<html>
<head>
<title>ShotDev.Com Tutorial</title>
</head>
<body>
<?php
$strDate = date_parse("2010-12-12 10:50:45");
echo $strDate["year"]."<br>";
echo $strDate["month"]."<br>";
echo $strDate["day"]."<br>";
echo "<hr>";
foreach($strDate as $key => $value) {
echo "Key: [$key] Value= $value<br>";
}
?>
</body>
</html>

</br>

Create a php file and save to path root-path/myphp/

Run
http://localhost/myphp/php_date_parse.php

Screenshot

PHP date_parse()
.
.
.

Download this script.
Download

1 Star2 Stars3 Stars4 Stars5 Stars6 Stars7 Stars8 Stars9 Stars10 Stars (1 votes, average: 1.00 out of 10)
Loading ... Loading ...

Leave a Reply

You must be logged in to post a comment.