arrayrule.class.php

来自「一个用PHP编写的」· PHP 代码 · 共 32 行

PHP
32
字号
<?php    lt_include(PLOG_CLASS_PATH."class/data/validator/rules/rule.class.php");		/**	 * \ingroup Validator_Rules	 *	 * Implements a rule that checks if the input is a valid php array (used	 * in cases when we'd like to validate if something coming from $_GET or $_POST	 * is an array)	 */    class ArrayRule extends Rule    {        /**         * Initializes the rule         */        function ArrayRule()        {            $this->Rule();        }        /**         * Validates the data.         *         * @param value The array that we'd like to validate         */        function validate($value)        {			return( is_array($value));        }    }?>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?