PHP Package: mlocati/ip-lib
IP-lib is a PHP library for handling IP addresses efficiently and accurately, providing useful tools for IP address validation, manipulation, and geolocation.
Package Description
IP-lib is a versatile PHP library designed to simplify the handling of IP addresses with precision and efficiency. With a range of functions for IP address validation, manipulation, and geolocation, this library streamlines the process of working with IP data, making it an indispensable tool for developers working on networking or geolocation projects.
Download Latest Version: 1.21.0

Previous Versions
Code Integration Example
Make sure to include the correct namespace and class paths for proper usage.
<?php
// Example from PHPlibraries.com
require_once 'libs/mlocati/ip-lib/1.21.0/loader.php';
require_once 'libs/mlocati/php-cs-fixer-config/{lib_version}/loader.php';
require_once 'libs/php-fig/log/3.0.2/loader.php';
use MLocati\IP\IPAddress;
use MLocati\IP\IPv4Address;
use MLocati\IP\IPv6Address;
$obj = new IPAddress();
echo '✅ Test OK: ' . get_class($obj);
?>
We aim to make using PHP packages easier without Composer. If something doesn't work, let us know — we'll fix it promptly.
Community Discussion
Ask questions, share tips, or report issues below.