stEmail($key)
{
if (Zend_Filter::isEmail($this->_source[$key])) {
return $this->_source[$key];
}
return FALSE;
}
/**
* Returns value if it is a valid float value, FALSE otherwise.
*
* @param mixed $key
* @return mixed
*/
public function testFloat($key)
{
if (Zend_Filter::isFloat($this->_source[$key])) {
return $this->_source[$key];
}
return FALSE;
}
/**
* Returns value if it is greater than $min, FALSE otherwise.
*
* @param mixed $key
* @param mixed $min
* @return mixed
*/
public function testGreaterThan($key, $min = NULL)
{
if (Zend_Filter::isGreaterThan($this->_source[$key], $min)) {
return $this->_source[$key];
}
return FALSE;
}
/**
* Returns value if it is a valid hexadecimal format, FALSE
* otherwise.
*
* @param mixed $key
* @return mixed
*/
public function testHex($key)
{
if (Zend_Filter::isHex($this->_source[$key])) {
return $this->_source[$key];
}
return FALSE;
}
/**
* Returns value if it is a valid hostname, FALSE otherwise.
* Depending upon the value of $allow, Internet domain names, IP
* addresses, and/or local network names are considered valid.
* The default is HOST_ALLOW_ALL, which considers all of the
* above to be valid.
*
* @param mixed $key
* @param integer $allow bitfield for HOST_ALLOW_DNS, HOST_ALLOW_IP, HOST_ALLOW_LOCAL
* @throws Zend_Filter_Exception
* @return mixed
*/
public function testHostname($key, $allow = Zend_Filter::HOST_ALLOW_ALL)
{
if (Zend_Filter::isHostname($this->_source[$key], $allow)) {
return $this->_source[$key];
}
return FALSE;
}
/**
* Returns value if it is a valid integer value, FALSE otherwise.
*
* @param mixed $key
* @return mixed
*/
public function testInt($key)
{
if (Zend_Filter::isInt($this->_source[$key])) {
return $this->_source[$key];
}
return FALSE;
}
/**
* Returns value if it is a valid IP format, FALSE otherwise.
*
* @param mixed $key
* @return mixed
*/
public