How to compare two dates in php

前端 未结 15 2442
臣服心动
臣服心动 2020-11-22 08:37

How to compare two dates in php if dates are in format \'03_01_12\' and \'31_12_11\' .

I am using this code:

$date1=date(\'         


        
15条回答
  •  醉话见心
    2020-11-22 09:12

    format("%R%a")>0){
                 echo "active";
           }else{
               echo "inactive";
           }
           echo "Remaining Days ".$diff->format("%R%a days");
    ?>
    

提交回复
热议问题