Utility methods for IPv4 addresses

author Barry O'Donovan
author The Skilled Team of PHP Developers at Open Solutions
category OSS
package OSS_Form
copyright Copyright (c) 2007 - 2013, Open Source Solutions Limited, Dublin, Ireland
license New BSD License

 Methods

Converts IPv4 address to its in-addr.arpa format

ipv4ToARPA(string $ip) : string
Static

E.g. IPv4 address like 1.2.3.4 will be converted to 4.3.2.1.in-addr.arpa.

Parameters

$ip

string

IPv4 address to convert

Exceptions

\OSS_Net_Execption On lose checking of IPv4 address format (four octets)

Returns

stringThe in-addr.arpa version of the IPv4 address