當前位置: 首頁>>代碼示例>>PHP>>正文


PHP JFormHelper::loadRuleClass方法代碼示例

本文整理匯總了PHP中JFormHelper::loadRuleClass方法的典型用法代碼示例。如果您正苦於以下問題:PHP JFormHelper::loadRuleClass方法的具體用法?PHP JFormHelper::loadRuleClass怎麽用?PHP JFormHelper::loadRuleClass使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在JFormHelper的用法示例。


在下文中一共展示了JFormHelper::loadRuleClass方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: loadRuleClass

 /**
  * Helper wrapper method for loadRuleClass
  *
  * @param   string  $type  Type of a rule whose class should be loaded.
  *
  * @return mixed  Class name on success or false otherwise.
  *
  * @see     JFormHelper::loadRuleClass()
  * @since   3.4
  */
 public function loadRuleClass($type)
 {
     return JFormHelper::loadRuleClass($type);
 }
開發者ID:deenison,項目名稱:joomla-cms,代碼行數:14,代碼來源:helper.php

示例2: defined

<?php

/**
 * @package     Joomla.Site
 * @subpackage  com_contact
 *
 * @copyright   Copyright (C) 2005 - 2016 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
defined('_JEXEC') or die;
use Joomla\Registry\Registry;
use Joomla\String\StringHelper;
JFormHelper::loadRuleClass('email');
/**
 * JFormRule for com_contact to make sure the email address is not blocked.
 *
 * @since  1.6
 */
class JFormRuleContactEmail extends JFormRuleEmail
{
    /**
     * Method to test for banned email addresses
     *
     * @param   SimpleXMLElement  $element  The SimpleXMLElement object representing the <field /> tag for the form field object.
     * @param   mixed             $value    The form field value to validate.
     * @param   string            $group    The field name group control value. This acts as as an array container for the field.
     *                                      For example if the field has name="foo" and the group value is set to "bar" then the
     *                                      full field name would end up being "bar[foo]".
     * @param   Registry          $input    An optional Registry object with the entire data set to validate against the entire form.
     * @param   JForm             $form     The form object for which the field is being tested.
     *
開發者ID:eshiol,項目名稱:joomla-cms,代碼行數:31,代碼來源:contactemail.php

示例3: defined

<?php

/**
 * Created by JetBrains PhpStorm.
 * User: Ngoc Nha
 * Date: 4/14/13
 * Time: 5:17 PM
 * To change this template use File | Settings | File Templates.
 */
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
// import Joomla formrule library
//jimport('joomla.form.rule');
JFormHelper::loadRuleClass('greeting');
/**
 * Form Rule class for the Joomla Framework.
 */
class JFormRuleGreeting extends JFormRule
{
    /**
     * The regular expression.
     *
     * @access      protected
     * @var         string
     * @since       2.5
     */
    protected $regex = '^[^0-9]+$';
}
開發者ID:prox91,項目名稱:joomla-dev,代碼行數:28,代碼來源:greeting.php


注:本文中的JFormHelper::loadRuleClass方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。