IP to Number converts an IP address into a decimal number, commonly used in database field design where standard IP format needs to be converted into a decimal number. This conversion must follow the following algorithm:
The first octet (leftmost) must be multiplied by 16777216 (256^3).
The second octet must be multiplied by 65536 (256^2).
The third octet must be multiplied by 256.
All obtained values, including the fourth octet, must be summed (formally, the fourth octet must be multiplied by 256^0, i.e., by one).