芝麻web文件管理V1.00
编辑当前文件:/home2/sdektunc/www/cepali/lib/pear/HTML/QuickForm/Rule.php
| // +----------------------------------------------------------------------+ // // $Id$ class HTML_QuickForm_Rule { /** * Name of the rule to use in validate method * * This property is used in more global rules like Callback and Regex * to determine which callback and which regex is to be used for validation * * @var string * @access public */ var $name; /** * Validates a value * * @access public * @abstract */ function validate($value, $options = null) { return true; } /** * Sets the rule name * * @access public */ function setName($ruleName) { $this->name = $ruleName; } /** * Returns the javascript test (the test should return true if the value is INVALID) * * @param mixed Options for the rule * @access public * @return array first element is code to setup validation, second is the check itself */ function getValidationScript($options = null) { return array('', ''); } } ?>