import random crap zend files
[hiphop-php.git] / hphp / test / zend / bad / ext-date / localtime_variation3.php
blob6ea7f42f1f2322a3013bfd9e8c65c148bd2c9a0c
1 <?php
2 /* Prototype : array localtime([int timestamp [, bool associative_array]])
3 * Description: Returns the results of the C system call localtime as an associative array
4 * if the associative_array argument is set to 1 other wise it is a regular array
5 * Source code: ext/date/php_date.c
6 * Alias to functions:
7 */
9 echo "*** Testing localtime() : usage variation ***\n";
11 date_default_timezone_set("UTC");
12 // Initialise function arguments not being substituted (if any)
13 $is_associative = true;
15 echo "\n-- Testing localtime() function with 'float 12.3456789000e10' to timestamp --\n";
16 $timestamp = 12.3456789000e10;
17 var_dump( localtime($timestamp) );
18 var_dump( localtime($timestamp, $is_associative) );
20 echo "\n-- Testing localtime() function with 'float -12.3456789000e10' to timestamp --\n";
21 $timestamp = -12.3456789000e10;
22 var_dump( localtime($timestamp) );
23 var_dump( localtime($timestamp, $is_associative) );
26 ===DONE===