PHP - Getting Yesterday\'s Date in PHP

/ Published in: PHP
Save to your folder(s)

Example calculate yesterday, but if you multiply by some number you can get in an easy way, weeks, months or years

Copy this code and paste it in your HTML
  1. date("Y-m-d", time() - (60*60*24) ); // get Yesterday date


Report this snippet


RSS Icon Subscribe to comments

You need to login to post a comment.