Yii 2.0 How to generate form without
?

前端 未结 4 1224
抹茶落季
抹茶落季 2021-02-02 09:30
 \'contact-form\']); ?>
        field($model, \'email\',  [
                \'inputOptions\' => [          


        
4条回答
  •  无人及你
    2021-02-02 09:56

    I have solved it like this....put tag as span.. also you can prepend icons infront of the box.

    'login-form', 'options' => ['role'=>'form'], 'fieldConfig' => [ 'options' => [ 'tag' => 'span', ], ], ]); ?> field($model, 'username',[ 'template' => '
    {input}
    {error}', 'inputOptions' => [ 'placeholder' => 'Username ...', 'class'=>'form-control', ]]) ?> field($model, 'password', [ 'template' => '
    {input}
    {error}', 'inputOptions' => [ 'placeholder' => 'Password ...', 'class'=>'form-control', ]])->input('password') ?>

提交回复
热议问题