inet_ntop

PHP 5 >= 5.1.0, PHP 7, PHP 8
inet_ntop - Converts a packed internet address to a human readable representation
Manual
Code Examples

inet_ntop( string$ip ): string|false

This function converts a 32bit IPv4, or 128bit IPv6 address (if PHP was built with IPv6 support enabled) into an address family appropriate string representation.

Parameters

ip

A 32bit IPv4, or 128bit IPv6 address.

Return Values

Returns a string representation of the address or false on failure.

Related Functions

Example of inet_ntop

Show all examples for inet_ntop

PHP Version: