Validate IP address

Uses filter_var() function to validate IP address. Read more.

php
fork add to bundle source
function check_ip($ip) { return filter_var($ip, FILTER_VALIDATE_IP) ? true : false; }

usage

load_function('check_ip'); check_ip('8.8.8.8'); // (true) check_ip('8_8_8_8'); // (false)
← how to use this in app?
create log ...inout