1
0
mirror of synced 2025-01-31 20:41:44 +03:00
doctrine2/classes/Validator/Regexp.class.php

18 lines
404 B
PHP
Raw Normal View History

2006-04-13 20:37:28 +00:00
<?php
class Doctrine_Validator_Regexp {
/**
* @param Doctrine_Record $record
* @param string $key
* @param mixed $value
* @param string $args
2006-04-13 20:37:28 +00:00
* @return boolean
*/
public function validate(Doctrine_Record $record, $key, $value, $args) {
2006-05-26 11:32:35 +00:00
if(preg_match("/$args/", $value))
return true;
return false;
2006-04-13 20:37:28 +00:00
}
}
?>