I have searched high and low and can´t seem to remember how to do this:
Show Yesterday or another date in the past in JS.
If I rember correctly it is a simple bit of code.
Thanks
var yesterday = new Date(Date.now() - 864e5); // 864e5 == 86400000 == 24*60*60*1000
hth