摘要: $alldays = intval((sstrtotime($_POST['dayb']) - sstrtotime($_POST['daya'])) / 3600 / 24) + 1; //总天数 $weeks = intval($alldays / 7); //纯周数 $mdays = $alldays - 7 * $weeks; //除了纯周数外,余下那周的天数 if($mdays == '0') { $_POST['psdays'] = 5 * $weeks; $_POST['zmdays'] = 2 * 阅读全文