CoreFiles by mySites.guru
ModuleLayoutRule.php37 lines, 1,060 bytes, from Joomla_4.2.0-beta2-Beta-Full_Package.zip
Raw History Compare with 4.2.0-beta1
md5
70691b69e598ae91ef70d7a58a386e81
sha1
d269576f68ecf67cb0b78f05b21ca1f0ccb8b965
sha256
6239ec8c61546df0ca3cb2f5d5852706ac5dbc299f38ddf8d71d97b3063d9086
<?php
/**
 * Joomla! Content Management System
 *
 * @copyright  (C) 2021 Open Source Matters, Inc. <https://www.joomla.org>
 * @license    GNU General Public License version 2 or later; see LICENSE.txt
 */

namespace Joomla\CMS\Form\Rule;

defined('JPATH_PLATFORM') or die;

use Joomla\CMS\Form\FormRule;

/**
 * Form Rule class for the Joomla Platform.
 *
 * @since  3.9.26
 */
class ModuleLayoutRule extends FormRule
{
	/**
	 * The regular expression to use in testing a module layout field value.
	 *
	 * A valid module layout field value consists of
	 * - optionally a template name with only characters, numbers, hyphens and
	 *   underscores, which can also be just "_" for layouts provided by the
	 *   module, followed by a colon.
	 * - the base name of the layout file, not starting with a dot and with
	 *   only characters, numbers, dots and hyphens but no underscores (see
	 *   method "getInput" of the "ModuleLayout" field).
	 *
	 * @var    string
	 * @since  3.9.26
	 */
	protected $regex = '^([A-Za-z0-9_-]+:)?[A-Za-z0-9-][A-Za-z0-9\.-]*$';
}

The same content is in 75 releases, Joomla 3.9.27-rc to 4.2.0-beta2. See them all, or every version of this file.