View Single Post
Old 01-13-2023, 03:59 AM  
Publisher Bucks
Confirmed User
 
Industry Role:
Join Date: Oct 2018
Location: New Orleans, Louisiana.
Posts: 653
Php date problem 'Y' displying 1969

Why is this code displaying 'Y' as 1969?

Quote:
<?php

$today = date("d");
$thisMonth = date("M");
$thisYear = date("Y");
echo date("M d Y", mktime(0,0,0, $thisMonth, $today, $today-8));

?>
I'm trying to get it to display: Jan 5 2023 (minus 8 days from today).
__________________
PublisherBucks
Wellness Affiliate Program.
Publisher Bucks is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote