SHARE
TWEET

Error when calling PHP function

dominornovus Oct 17th, 2012 49 Never
  1. <?php
  2.  
  3. //http://stackoverflow.com/a/12944764/835950
  4.  
  5. $older = "2012-11-01";
  6. $newer = "2012-12-25";
  7. get_timespan_string($older, $newer);
  8.  
  9. // Produces this error: "Fatal error: Call to a member function format() on a non-object[...]"
  10.  
  11. ?>
RAW Paste Data
Top