Your IP : 216.73.216.240


Current Path : /home/juvelize/www/libraries/ic_library/Rule/IC/
Upload File :
Current File : /home/juvelize/www/libraries/ic_library/Rule/IC/PositiveIntegerRule.php

<?php
/**
 *----------------------------------------------------------------------------
 * iC Library   Library by Jooml!C, for Joomla!
 *----------------------------------------------------------------------------
 * @version     2.2.0 2024-02-17
 *
 * @package     iC Library
 * @subpackage  Rule.IC
 * @link        https://www.joomlic.com
 *
 * @author      Cyril Rezé
 * @copyright   (c) 2013-2024 Cyril Rezé / iCagenda. All rights reserved.
 * @license     GNU General Public License version 3 or later; see LICENSE.txt
 *
 * @since       1.4.2
 *----------------------------------------------------------------------------
*/

namespace iClib\Rule\IC;

\defined('JPATH_PLATFORM') or die;

use Joomla\CMS\Form\FormRule;

/**
 * Form Rule class.
 *
 * Positive integer validation.
 */
class PositiveIntegerRule extends FormRule
{
	/**
	 * The regular expression to use in testing a form field value.
	 *
	 * @var  string
	 */
	protected $regex = '^(\s*|[1-9][0-9]*$)$';
}