<?php $form = ActiveForm::begin([
'options'=>['enctype'=>'multipart/form-data','class' => 'form-horizontal'],
'fieldConfig' => [
'template' => "{label}\n<div class=\"col-lg-5\">{input}</div>\n<div class=\"col-lg-3\">{error}</div>",
'labelOptions' => ['class' => 'col-lg-1 control-label'], //修改label的样式
]
]); ?>