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


PHP sfWidgetForm::__construct方法代碼示例

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


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

示例1: __construct

 /**
  * Constructor.
  *
  * Available options:
  *
  *  * public_key:        Your reCAPTCHA public key (app_recaptcha_private_key by default)
  *  * error:             A reCAPTCHA error code
  *  * use_ssl:           Use a secure connection (false by default)
  *
  * @param array  $options An array of options
  * @param array  $messages An array of error messages
  *
  * @see sfWidgetForm
  */
 public function __construct($options = array(), $attributes = array())
 {
     $this->addOption('public_key', sfConfig::get('app_recaptcha_public_key'));
     $this->addOption('error', null);
     $this->addOption('use_ssl', false);
     parent::__construct($options, $attributes);
 }
開發者ID:kidh0,項目名稱:swbrasil,代碼行數:21,代碼來源:sfAnotherWidgetFormReCaptcha.class.php

示例2: __construct

 public function __construct($options = array(), $attributes = array())
 {
     $this->addOption('empty_value', ' ');
     $this->addOption('value_callback', null);
     $this->addOption('plain', true);
     parent::__construct($options, $attributes);
 }
開發者ID:nvidela,項目名稱:kimkelen,代碼行數:7,代碼來源:ncWidgetFormReadOnly.php

示例3: __construct

 /**
  * Constructor.
  * 
  * @param array $options     An array of options
  * @param array $attributes  An array of default HTML attributes
  *
  * @see sfWidgetForm
  */
 public function __construct($options = array(), $attributes = array())
 {
     $this->addRequiredOption('widget');
     $this->addOption('is_edit_public_flag', false);
     $this->addOption('public_flag_default', 1);
     $this->addOption('template', '%input%<br>%public_flag%');
     parent::__construct($options, $attributes);
     $this->setLabel($this->getOption('widget')->getLabel());
 }
開發者ID:Kazuhiro-Murota,項目名稱:OpenPNE3,代碼行數:17,代碼來源:opWidgetFormProfile.class.php

示例4: __construct

 public function __construct($options = array(), $attributes = array())
 {
     $this->addOption('object', null);
     $this->addOption('method', null);
     $this->addOption('method_args', null);
     $this->addOption('add_hidden_input', false);
     $this->addOption('true_string', 'Yes');
     $this->addOption('false_string', 'No');
     parent::__construct($options, $attributes);
 }
開發者ID:nvidela,項目名稱:kimkelen,代碼行數:10,代碼來源:mtWidgetFormPlainBoolean.class.php

示例5: __construct

 public function __construct($options = array(), $attributes = array())
 {
     $this->addOption('object');
     $this->addOption('method', '__toString');
     $this->addOption('method_args', null);
     $this->addOption('use_retrieved_value', true);
     $this->addOption('empty_value', '&nbsp;');
     $this->addOption('add_hidden_input', false);
     $this->addOption('value_callback', null);
     parent::__construct($options, $attributes);
 }
開發者ID:nvidela,項目名稱:kimkelen,代碼行數:11,代碼來源:mtWidgetFormPlain.php

示例6: __construct

 public function __construct($options = array(), $attributes = array())
 {
     $this->addOption('object', null);
     $this->addOption('method', null);
     $this->addOption('empty_value', '&nbsp;');
     $this->addOption('collapse', false);
     $this->addOption('restrict_size', false);
     $this->addOption('restricted_size', 125);
     $this->addOption('add_hidden_input', false);
     $this->addOption('hidden_input_value', null);
     $this->addOption('value_callback', null);
     $this->addOption('to_string_method', '__toString');
     parent::__construct($options, $attributes);
 }
開發者ID:nvidela,項目名稱:kimkelen,代碼行數:14,代碼來源:sfWidgetFormPlainMany.class.php

示例7: __construct

 /**
  * Constructor.
  *
  * The first argument can be:
  *
  *  * null
  *  * an array of sfWidget instances
  *
  * Available options:
  *
  *  * name_format:    The sprintf pattern to use for input names
  *  * form_formatter: The form formatter name (table and list are bundled)
  *
  * @param mixed $fields     Initial fields
  * @param array $options    An array of options
  * @param array $attributes An array of default HTML attributes
  * @param array $labels     An array of HTML labels
  * @param array $helps      An array of help texts
  *
  * @see sfWidgetForm
  */
 public function __construct($fields = null, $options = array(), $attributes = array(), $labels = array(), $helps = array())
 {
     $this->addOption('name_format', '%s');
     $this->addOption('form_formatter', null);
     parent::__construct($options, $attributes);
     if (is_array($fields)) {
         foreach ($fields as $name => $widget) {
             $this[$name] = $widget;
         }
     } else {
         if (!is_null($fields)) {
             throw new InvalidArgumentException('sfWidgetFormSchema constructor takes an array of sfWidget objects.');
         }
     }
     $this->setLabels($labels);
     $this->helps = $helps;
 }
開發者ID:Esleelkartea,項目名稱:legedia-ESLE,代碼行數:38,代碼來源:sfWidgetFormSchema.class.php

示例8: __construct

 public function __construct($options = array(), $attributes = array())
 {
     parent::__construct($options, $attributes);
     $this->validateOptions();
 }
開發者ID:nvidela,項目名稱:kimkelen,代碼行數:5,代碼來源:crWidgetFormSelectableWidget.class.php

示例9: __construct

 public function __construct($options = array(), $attributes = array())
 {
     $this->addOption('type', 'text');
     parent::__construct($options, $attributes);
 }
開發者ID:te-koyama,項目名稱:openpne,代碼行數:5,代碼來源:opWidgetFormInputIncreased.class.php


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