
PHP script to get current date.

Hi,
You can use the following code to print the current in PHP:
<?php echo date('y m d'); ?>
With the help of following code you can get the current date in a variable:
<?
$today = date("F j, Y, g:i a");
?>
Today is: <?=$today?>
More tutorial on PHP date are available at: http://www.roseindia.net/tutorial/php/php-date-function.html
and
http://www.roseindia.net/tutorial/php/phpdate/phpdateandtime.html
Thanks
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.