echo $a=ip2long ("202.97.224.68");
echo "
-
";
echo long2ip ($a);
Note: There is something to note here. Probably because PHP cannot correctly determine the converted number type, negative numbers appear.
At this time, you can use bindec(decbin(ip2long($IP))) to process it.
http://www.bkjia.com/PHPjc/486453.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/486453.htmlTechArticleecho $a=ip2long (202.97.224.68); echo br /-br /; echo long2ip ($a) ; Note: There is something to note here. Probably because PHP cannot correctly determine the converted number type, negative...
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn