Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!doctype html>
- <html>
- <head>
- <title>01.Print current date</title>
- <meta charset="utf8"/>
- </head>
- <body>
- <?php
- echo date('d-m-Y')."<br/>";
- echo date('d.m.y')."<br/>";
- echo date('d F Y')."<br/>";
- date_default_timezone_set("Europe/Sofia");
- echo "The time is ". date("H:i:s")."<br/>";
- echo "Today is ".date("l");
- /*
- d - Represents the day of the month (01 to 31)
- m - Represents a month (01 to 12)
- Y - Represents a year (in four digits)
- 1 - Represents the day of the week
- h - 12-hour format of an hour with leading zeros (01 to 12)
- i - Minutes with leading zeros (00 to 59)
- s - Seconds with leading zeros (00 to 59)
- a - Lowercase Ante meridiem and Post meridiem (am or pm)
- */
- ?>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement