Page 1 of 1

strtotime("next Wednesday")

Posted: Fri Feb 27, 2004 5:57 pm
by Shendemiar
return date("Y-m-d H:i:s", strtotime("next Wednesday"));

returns 2004-03-10 00:00:00

thats almost two weeks ahead.

So is there an easy way to get the timestamp of next wednesday (any other weekday), or should i reinvent the wheel?

Posted: Fri Feb 27, 2004 7:46 pm
by Shendemiar
Date gives the dayof week as a number from 0 to 6, i made a small function with that.