note 18056 added to function.ip2long

From: Date: Wed, 09 Jan 2002 09:04:26 +0000
Subject: note 18056 added to function.ip2long
Groups: php.notes 
Request: Send a blank email to php-notes+get-24562@lists.php.net to get a copy of this message
From my brief experimenting (it doesn't seem to mention this in the function notes) if there is an alphabetic character in the ip it will return -1, if it is a non valid numeric number it will still return a value. I would prefer the function validated that its input was a valid IP in all cases, but seeing as it doesn't you will need to do this yourself. -- http://www.php.net/manual/en/function.ip2long.php http://master.php.net/manage/user-notes.php?action=edit+18056 http://master.php.net/manage/user-notes.php?action=delete+18056 http://master.php.net/manage/user-notes.php?action=reject+18056

« previous php.notes (#24562) next »