$netaddr = inet_aton($dotquad); Convert a dot-quad IP address into an IPv4 packed network address. inet_aton HOSTNAME Takes a string giving the name of a host, and translates that to the 4-byte string (structure). Takes arguments of both the 'rtfm.mit.edu' type and '18.181.0.24'. If the host name cannot be resolved, returns undef.