# date –help 用法:date … 或:date YY]] 以给定的格式显示当前时间,或是设置系统日期。 -d,–date=字符串 ... Read More | Share it now!
Tag Archives: date
Linux date命令的用法
在linux shell编程中,经常用到日期的加减运算 以前都是自己通过expr函数计算,很麻烦 其实date命令本身提供了日期的加减运算 非常方便。例如:得到昨天的时间 date +%Y%m%d –date=”-1... Read More | Share it now!
PHP时间比较和时间差如何计算
<?php $zero1=date(“y-m-d h:i:s”); $zero2=”2010-11-29 21:07:00′; echo “zero1的时间为:”.$zero1.”<br>”; echo “zero2的时间为:”.$zero2.”<br>”; if(strtotime($zero1)<strtotime($zero2)){ echo... Read More | Share it now!