📄 templatenamevalidator.class.php
字号:
<?php lt_include( PLOG_CLASS_PATH."class/data/validator/validator.class.php" ); lt_include( PLOG_CLASS_PATH."class/data/validator/rules/regexprule.class.php" ); lt_include( PLOG_CLASS_PATH."class/data/validator/rules/nonemptyrule.class.php" ); define( "VALID_REGEXP_CHARS", "^([a-z0-9._-]+)$"); /** * \ingroup Validator * * Checks whether the string is a valid template name * * @see NonEmptyRule */ class TemplateNameValidator extends Validator { function TemplateNameValidator() { $this->Validator(); $this->addRule( new NonEmptyRule()); $this->addRule( new RegExpRule(VALID_REGEXP_CHARS, false )); } }?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -