gmstrftime_basic.phpt 692 B

12345678910111213141516171819202122232425
  1. --TEST--
  2. Test gmstrftime() function : basic functionality
  3. --FILE--
  4. <?php
  5. echo "*** Testing gmstrftime() : basic functionality ***\n";
  6. // Initialise all required variables
  7. $format = '%b %d %Y %H:%M:%S';
  8. $timestamp = gmmktime(8, 8, 8, 8, 8, 2008);
  9. // Calling gmstrftime() with all possible arguments
  10. var_dump( gmstrftime($format, $timestamp) );
  11. // Calling gmstrftime() with mandatory arguments
  12. var_dump( gmstrftime($format) );
  13. ?>
  14. --EXPECTF--
  15. *** Testing gmstrftime() : basic functionality ***
  16. Deprecated: Function gmstrftime() is deprecated in %s on line %d
  17. string(20) "Aug 08 2008 08:08:08"
  18. Deprecated: Function gmstrftime() is deprecated in %s on line %d
  19. string(%d) "%s %d %d %d:%d:%d"