taz321 Posted January 1, 2008 Share Posted January 1, 2008 Hi I'm wanting to put a date on my page so that it updates when i look at the same page on a new and different date. I am using Dreamweaver to do this and the program has the date function but the date doesnt update. Any clues on the code for this ? Im wanting the format - Tuesday January 1, 2008 Quote Link to comment https://forums.phpfreaks.com/topic/83985-inserting-a-date/ Share on other sites More sharing options...
revraz Posted January 1, 2008 Share Posted January 1, 2008 echo date("l F j, Y"); should do it Quote Link to comment https://forums.phpfreaks.com/topic/83985-inserting-a-date/#findComment-427374 Share on other sites More sharing options...
taz321 Posted January 1, 2008 Author Share Posted January 1, 2008 That peice of code doesnt appear to work, do i need other code to go along with this ? Thanks Quote Link to comment https://forums.phpfreaks.com/topic/83985-inserting-a-date/#findComment-427378 Share on other sites More sharing options...
Dane Posted January 1, 2008 Share Posted January 1, 2008 <?php $date = date("l F j, Y"); echo $date; ?> Quote Link to comment https://forums.phpfreaks.com/topic/83985-inserting-a-date/#findComment-427379 Share on other sites More sharing options...
taz321 Posted January 1, 2008 Author Share Posted January 1, 2008 Excellent thanks for that, hopefully when i check the page tomorrow the date should update. Thanks Quote Link to comment https://forums.phpfreaks.com/topic/83985-inserting-a-date/#findComment-427381 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.