コード例 #1
0
ファイル: date.class.php プロジェクト: magsilva/dotproject
 /**
 * New method to get the difference in days the stored date
 * @param Date The date to compare to
 * @author Andrew Eddie <*****@*****.**>
 */
 function dateDiff($when)
 {
     return Date_calc::dateDiff($this->getDay(), $this->getMonth(), $this->getYear(), $when->getDay(), $when->getMonth(), $when->getYear());
 }
コード例 #2
0
 /**
  * New method to get the difference in days the stored date
  * @param Date The date to compare to
  * @author Andrew Eddie <*****@*****.**>
  */
 public function dateDiff($when)
 {
     if (!is_object($when)) {
         return false;
     }
     return Date_calc::dateDiff($this->getDay(), $this->getMonth(), $this->getYear(), $when->getDay(), $when->getMonth(), $when->getYear());
 }