← All docs
inet_ntop()
Renders a packed 4-byte IPv4 or 16-byte IPv6 address as its presentation string, or false for any other length.
inet_ntop()
function inet_ntop(string $ip): mixed
Renders a packed 4-byte IPv4 or 16-byte IPv6 address as its presentation string, or false for any other length.
Parameters:
$ip(string)
Returns: mixed
Availability
- Compiled (AOT): supported by the Elephc code generator.
eval()(magician interpreter): supported through a declarative interpreter builtin (crates/elephc-magician/src/interpreter/builtins/network_env/inet_ntop.rs).
No examples yet. Check examples/ and showcases/ for usage patterns.
Internals
For how inet_ntop is implemented in the compiler, see the internals page.