3v4l.org

run code in 300+ PHP versions simultaneously
<?php function humanizeDayOfDate($date) { if( date('d.m.Y', strtotime($date)) == date('d.m.Y') ) { return 'Today'; } if( date('d.m.Y', strtotime($date)) == date('d.m.Y', strtotime('-1 day')) ) { return 'Yesterday'; } } echo humanizeDayOfDate('2013-03-05');

preferences:
38.66 ms | 402 KiB | 5 Q