- date: documentation ( source)
- strtotime: documentation ( source)
<?php
$str = strtotime('this Thursday');
if($this_thr_str <= strtotime("now")){
echo 'This thurs'."\n";
$thrs = date('mdy',$str);
}else{
echo 'Last Thurs'."\n";
$str = strtotime('last Tuesday');
$thrs = date('mdy',$str);
}
$link = 'http://marc.ucla.edu/mpeg/Hammer'.$thrs.'.mp3';
echo $link;
//
//echo date('mdy',$tuestr);