note 110996 deleted from function.ip2long by aharvey
| From: | aharvey@php.net | Date: | Tue, 08 Jan 2013 02:48:46 +0000 |
| Subject: | note 110996 deleted from function.ip2long by aharvey | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-192818@lists.php.net to get a copy of this message | ||
Note Submitter: Anonymous
----
Here's how to do it the hard way:
<?php
ip2long($_SERVER['REMOTE_ADDR']) === hexdec(vsprintf('%02x%02x%02x%02x',
explode('.', $_SERVER['REMOTE_ADDR'])));
?>