frame

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Register

PHP Date and Time

PHP Date and Time

Format today's date in several ways

<!DOCTYPE html>
<html>
<body>


<?php
echo "Today is " . date("Y/m/d") . "<br>";
echo "Today is " . date("Y.m.d") . "<br>";
echo "Today is " . date("Y-m-d") . "<br>";
echo "Today is " . date("l");
?>


</body>
</html>


Automatically update the copyright year on your website

<!DOCTYPE html>
<html>
<body>


© 2010-<?php echo date("Y");?>


</body>
</html>


Output the current time (server time)


</html>Set Time zone, then output current time


</html>eate a date and time from a number of parameters in mktime()


Create a date and time from the strtotime() function


Create more dates/times from strtotime()


Output the dates for the next six Saturdays


Output the number of days until 4th of July


Sign In or Register to comment.

Developer

| make vanilla clean and light
@ 2016 Your Sitename, All rights reserved. Material Design is a design language developed by Google. Material Design makes more liberal use of grid-based layouts and responsive animations and transitions.
Powered by VanillaForums, Designed by ThemeSteam

Contact us

info@example.com
support@example.com
(800) 3032120

Get In Touch