3v4l.org

run code in 300+ PHP versions simultaneously
<?php //echo date('d-M-y'); //echo date('d-m-y H:i:s A' , strtotime( '29-APR-13 09.28.12.505032 pm')); $date = '29-APR-13 09.28.12.505032 PM'; $new_date = substr($date,0,18).substr($date, 25,28); $new_date = str_replace(".", ":", $new_date); //echo $new_date; //echo "\n"; $oracle_date = date('d/m/y H:i:s', strtotime($new_date)); echo $oracle_date; echo "\n"; echo date("d/m/y H:i:s"); $elapsed_time = round(abs(date("d/m/y H:i:s") - $oracle_date) / 60,2); echo "\n"; echo $elapsed_time;
Output for 8.0.0 - 8.0.12, 8.0.14 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
29/04/13 21:28:12 30/04/13 02:40:49 Warning: A non-numeric value encountered in /in/6ILqo on line 14 Warning: A non-numeric value encountered in /in/6ILqo on line 14 0.02
Output for 8.0.13
29/04/13 21:28:12 30/04/13 00:40:49 Warning: A non-numeric value encountered in /in/6ILqo on line 14 Warning: A non-numeric value encountered in /in/6ILqo on line 14 0.02
Output for 7.1.0 - 7.1.33, 7.2.0 - 7.2.33, 7.3.0 - 7.3.31, 7.4.0 - 7.4.25, 7.4.27 - 7.4.33
29/04/13 21:28:12 30/04/13 02:40:49 Notice: A non well formed numeric value encountered in /in/6ILqo on line 14 Notice: A non well formed numeric value encountered in /in/6ILqo on line 14 0.02
Output for 7.3.32 - 7.3.33, 7.4.26
29/04/13 21:28:12 30/04/13 00:40:49 0.02
Output for 4.3.0 - 4.3.11, 4.4.0 - 4.4.9, 5.0.0 - 5.0.5, 5.1.0 - 5.1.6, 5.2.0 - 5.2.17, 5.3.0 - 5.3.29, 5.4.0 - 5.4.45, 5.5.0 - 5.5.38, 5.6.0 - 5.6.40, 7.0.0 - 7.0.1, 7.0.3 - 7.0.33
29/04/13 21:28:12 30/04/13 02:40:49 0.02
Output for 7.0.2
29/04/13 21:28:12 30/04/13 02:40:50 0.02

preferences:
326.67 ms | 401 KiB | 460 Q