00001 <?php 00032 class Ipv4Filter implements FilterInterface 00033 { 00041 public static function execute ($s, $options) 00042 { 00043 $patron = '/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/'; 00044 if (preg_match($patron, $s, $regs)) { 00045 return $regs[0]; 00046 } else { 00047 return ""; 00048 } 00049 } 00050 }