extends abstract class Phalcon\Mvc\Model\Validator
implements Phalcon\Mvc\Model\ValidatorInterface
Source on GitHub
Phalcon\Mvc\Model\Validator\IP Validates that a value is ipv4 address in valid range
use Phalcon\Mvc\Model\Validator\Ip;
class Data extends Phalcon\Mvc\Model
{
public function validation()
{
// Any pubic IP
$this->validate(new IP(array(
'field' => 'server_ip',
'version' => IP::VERSION_4 | IP::VERSION_6, // v6 and