You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
j4examplecode/src/administrator/components/com_foos/src/Rule/LetterRule.php

38 lines
796 B

<?php
/**
* Joomla! Content Management System
*
* @copyright Copyright (C) 2005 - 2020 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace FooNamespace\Component\Foos\Administrator\Rule;
\defined('_JEXEC') or die;
use Joomla\CMS\Form\FormRule;
/**
* Form Rule class for the Joomla Platform.
*
* @since __DEPLOY_VERSION__
*/
class LetterRule extends FormRule
{
/**
* The regular expression to use in testing a form field value.
*
* @var string
* @since __DEPLOY_VERSION__
*/
protected $regex = '^([a-z]+)$';
/**
* The regular expression modifiers to use when testing a form field value.
*
* @var string
* @since __DEPLOY_VERSION__
*/
protected $modifiers = 'i';
}