<?php
$ips = array("129.51.31.51", "129.256.13.15", "255.255.255.255");
foreach ($ips as $ip) {
$v = ip2long($ip);
printf("%s %u\n", var_export($v, true), $v);
}
?>
PHP 4:
-2127356109 2167611187
-1 4294967295
-1 4294967295
PHP 5:
-2127356109 2167611187
false 0
-1 4294967295