3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $LastFridayOfMonth = date('Y-m-d', strtotime("last Friday", strtotime("2013-06-01"))); echo "$LastFridayOfMonth where 'month' is May\n" ; $LastFridayOfMonth = date('Y-m-d', strtotime("last Friday", strtotime("2013-07-01"))); echo "$LastFridayOfMonth where 'month' is June\n" ; $FirstFridayOfMonth = date('Y-m-d', strtotime("first Friday", strtotime("2013-10-31"))); echo "$LastFridayOfMonth where 'month' is November\n" ;
Output for 4.3.0 - 7.1.0
2013-05-31 where 'month' is May 2013-06-28 where 'month' is June 2013-06-28 where 'month' is November