php根据年月获取季度的方法

前端之家收集整理的这篇文章主要介绍了php根据年月获取季度的方法前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

代码如下:
PHP
function getQuarterByMonth($date){
$month = substr($date,-2);
$Q = ceil($month/3);
return $Q;
}
?>
@H_502_12@ 原文链接:https://www.f2er.com/php/24872.html

猜你在找的PHP相关文章