3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php date('Y_m_d_H_') . sprintf("%02d", (floor(date('i') / ROTATE_PERIOD) * ROTATE_PERIOD));
Output for 7.2.0 - 7.2.11
Warning: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' (this will throw an Error in a future version of PHP) in /in/56FLA on line 3 Warning: A non-numeric value encountered in /in/56FLA on line 3 Warning: Division by zero in /in/56FLA on line 3 Warning: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' (this will throw an Error in a future version of PHP) in /in/56FLA on line 3 Warning: A non-numeric value encountered in /in/56FLA on line 3
Output for 7.1.0 - 7.1.23
Notice: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' in /in/56FLA on line 3 Warning: A non-numeric value encountered in /in/56FLA on line 3 Warning: Division by zero in /in/56FLA on line 3 Notice: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' in /in/56FLA on line 3 Warning: A non-numeric value encountered in /in/56FLA on line 3
Output for 5.4.0 - 5.6.38, hhvm-3.10.1 - 3.21.3, 7.0.0 - 7.0.31
Notice: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' in /in/56FLA on line 3 Warning: Division by zero in /in/56FLA on line 3 Notice: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' in /in/56FLA on line 3
Output for hhvm-3.22.0
Notice: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' in /in/56FLA on line -1 Warning: Division by zero in /in/56FLA on line -1 Notice: Use of undefined constant ROTATE_PERIOD - assumed 'ROTATE_PERIOD' in /in/56FLA on line -1