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


PHP FormHelper::textarea方法代碼示例

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


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

示例1: textarea

 public function textarea($fieldName, $options, $before = false)
 {
     if ($before) {
         if ('textarea' === $options['type']) {
             $options += array('cols' => false, 'rows' => '3');
         }
         return $options;
     } else {
         return parent::textarea($fieldName, $options);
     }
 }
開發者ID:racklin,項目名稱:TwitterBootstrap,代碼行數:11,代碼來源:BootstrapFormHelper.php

示例2: render

 public function render()
 {
     $sResult = FormHelper::textarea($this->getAlias(), $this->getValue(), array('class' => 'redactor_content', 'id' => 'field_' . $this->getAlias()));
     $sResult .= '<script>$(document).ready(
         function()
         {
             $( \'#field_' . $this->getAlias() . '\' ).ckeditor();
         }
     );</script>';
     echo $sResult;
 }
開發者ID:ruxon,項目名稱:module-ruxon,代碼行數:11,代碼來源:RuxonFormViewRedactorColumn.class.php

示例3: textarea

 /**
  * FCK editor instance maken van textfield
  *
  * @param string $fieldName
  * @param array $options
  * @return string
  */
 function textarea($fieldName, $options = array())
 {
     $code = parent::textarea($fieldName, $options);
     $options = $this->_initInputField($fieldName, $options);
     $did = $options['id'];
     $js = $this->webroot . 'js/fck/';
     $code .= '<script type="text/javascript">' . "\n";
     $code .= "fckLoader_{$did} = function () {\n";
     $code .= "var bFCKeditor_{$did} = new FCKeditor('{$did}');\n";
     $code .= "bFCKeditor_{$did}.BasePath = '{$js}';\n";
     $code .= "bFCKeditor_{$did}.ToolbarSet = 'Default';\n";
     $code .= "bFCKeditor_{$did}.ReplaceTextarea();\n";
     $code .= "}\n";
     $code .= "fckLoader_{$did}();\n";
     $code .= "</script>";
     return $code;
 }
開發者ID:hafizubikm,項目名稱:bakeme,代碼行數:24,代碼來源:extended_form.php

示例4: textarea

 public function textarea($fieldName, $options = array())
 {
     $optionsDefault = array('class' => 'form-control');
     $options = array_merge_recursive($optionsDefault, $options);
     return parent::textarea($fieldName, $options);
 }
開發者ID:brnagn7,項目名稱:spydercake,代碼行數:6,代碼來源:CakePHPFTPFormHelper.php

示例5: testTextarea

 public function testTextarea()
 {
     $this->assertEqual(FormHelper::textarea('name', 'value', array('class' => 'myClass')), '<textarea name="name" class="myClass" id="name">value</textarea>');
     $this->assertEqual(FormHelper::textarea('name', $this->Model, array('class' => 'myClass')), '<textarea name="name" class="myClass" id="name">obj</textarea>');
 }
開發者ID:nicolasmartin,項目名稱:framework,代碼行數:5,代碼來源:helper.form.php

示例6: testTextarea

 public function testTextarea()
 {
     $html = $this->object->textarea('element', 'inner text', array('arbitrary' => 'arbitrary', 'class' => 'test-class'));
     $this->assertAttributes($html, array('class' => array('test-class', 'ccm-input-textarea'), 'arbitrary' => 'arbitrary'));
 }
開發者ID:notzen,項目名稱:concrete5-tests,代碼行數:5,代碼來源:FormHelperTest.php

示例7: array

<div class="row">
    <div class="col-md-6">
        <?php 
FormHelper::input('valor', 'Valor', $r['valor'], array());
?>
    </div>
    <div class="col-md-6">
        <?php 
FormHelper::input('custo', 'Custo', $r['custo'], array());
?>
    </div>
</div>
<input type='hidden' value='0' id="finalizar" name='finalizar'/>
<?php 
if ($ident && $r['finalizado'] == "0" || !$ident) {
    FormHelper::textarea('observacao', 'Observação', '', array());
}
$obs = array();
if ($ident) {
    $obs = "select \n    observacao,\n    datetime,\n    (select name from user where o.user_id = id) as usuario\n    from suporte_observacao o where suporte_id = " . $ident . " order by datetime desc";
    $obs = $db->query($obs);
}
FormHelper::submitAjax('Salvar', 'salvar', array('class' => 'button', 'style' => 'margin:5px'));
if ($ident && $r['finalizado'] == "0") {
    ?>
<button 
            type="button"
            class ='button'
            style='margin:5px 15px 5px 5px;float:right'
            onclick="finalizaSuporte_Sender(event,1)">Finalizar</button>
    <?php 
開發者ID:neurosoftbrasil,項目名稱:adminns,代碼行數:31,代碼來源:editar.php

示例8: array

        <?php 
FormHelper::input('cidade', "Cidade", $cidade, array('placeholder' => 'Digite a cidade'));
?>
                </div>
                <div class="col-md-5">
        <?php 
FormHelper::input('estado', "Estado", $cidade, array('placeholder' => 'UF'));
?>
                </div>
            </div>
            <div class="row">
                <div class="col-md-12">
        <?php 
FormHelper::textarea('complemento', "Complemento");
?>
                </div>
                
            <?php 
FormHelper::textarea('referencia', "Referência / observação");
?>
</div><?php 
FormHelper::end(false);
?>
</div>
<div class="modal-footer">  
    <button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
    <button type="button" class="btn btn-primary" onclick="App.Endereco.Salvar()">Salvar</button>
</div>
<script type="text/javascript">
    $("#formEndereco")[0].reset();
</script>
開發者ID:neurosoftbrasil,項目名稱:adminns,代碼行數:31,代碼來源:inserir.php

示例9: textarea

 /**
  * Creates a textarea widget.
  *
  * ### Options:
  *
  * - `escape` - Whether or not the contents of the textarea should be escaped. Defaults to true.
  *
  * @param string $fieldName Name of a field, in the form "Modelname.fieldname"
  * @param array $options Array of HTML attributes, and special options above.
  * @return string A generated HTML text input element
  * @access public
  * @link http://book.cakephp.org/view/1433/textarea
  */
 public function textarea($fieldName, $options = array())
 {
     $options = $this->_addPlaceholder($fieldName, $options);
     return parent::textarea($fieldName, $options);
 }
開發者ID:novrian,項目名稱:BakingPlate,代碼行數:18,代碼來源:FormPlusHelper.php

示例10: textarea

 public function textarea($fieldName, $options = array(), $tinyoptions = array()) {
     $this->_build($fieldName, $tinyoptions);
     return parent::textarea($fieldName, $options);
 }
開發者ID:rich97,項目名稱:cmp,代碼行數:4,代碼來源:tiny_mce.php

示例11: render

 public function render()
 {
     echo FormHelper::textarea($this->getAlias(), $this->getValue(), \ArrayHelper::merge(array('class' => 'TextboxField', 'id' => 'field_' . $this->getAlias()), $this->getHtmlOptions()));
 }
開發者ID:ruxon,項目名稱:module-ruxon,代碼行數:4,代碼來源:RuxonFormViewTextColumn.class.php

示例12: textarea

 /**
  * Creates a textarea widget.
  *
  * ### Options:
  *
  * - `escape` - Whether or not the contents of the textarea should be escaped. Defaults to true.
  *
  * @param string $fieldName Name of a field, in the form "Modelname.fieldname"
  * @param array $options Array of HTML attributes, and special options above.
  * @return string A generated HTML text input element
  * @link http://book.cakephp.org/2.0/en/core-libraries/helpers/form.html#FormHelper::textarea
  */
 public function textarea($fieldName, $options = array())
 {
     $options['normalize'] = false;
     return parent::textarea($fieldName, $options);
 }
開發者ID:miznokruge,項目名稱:base-cake,代碼行數:17,代碼來源:FormExtHelper.php


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