3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $ip = '192.168.21.1 - 192.168.21.254'; $ip = explode('-', $ip); list($lower, $upper) = $ip; $lower_dec = (float) sprintf("%u", ip2long($lower)); $upper_dec = (float) sprintf("%u", ip2long($upper)); print_r(ip2long($lower)); print_r(ip2long($upper));
Output for 5.2.10 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
Output for 5.0.0 - 5.2.9
3232240897
Output for 4.3.5 - 4.4.9
3232240897-1
Output for 4.3.0 - 4.3.4
32322408974294967295