note 94188 added to datetime.diff

From: Date: Wed, 21 Oct 2009 16:43:11 +0000
Subject: note 94188 added to datetime.diff
Groups: php.notes 
Request: Send a blank email to php-notes+get-161948@lists.php.net to get a copy of this message
the previous code didn't work. But this one does : <?php $Today = new DateTime(); $DateAction = new DateTime('2009-08-10'); $Difference = $Today->diff($DateAction); echo 'the difference is '. $Difference->d .'days'; ?> ---- Server IP: 69.147.83.197 Probable Submitter: 86.219.135.15 ---- Manual Page -- http://www.php.net/manual/en/datetime.diff.php Edit -- https://master.php.net/note/edit/94188 Del: integrated -- https://master.php.net/note/delete/94188/integrated Del: useless -- https://master.php.net/note/delete/94188/useless Del: bad code -- https://master.php.net/note/delete/94188/bad+code Del: spam -- https://master.php.net/note/delete/94188/spam Del: non-english -- https://master.php.net/note/delete/94188/non-english Del: in docs -- https://master.php.net/note/delete/94188/in+docs Del: other reasons-- https://master.php.net/note/delete/94188 Reject -- https://master.php.net/note/reject/94188 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#161948) next »