$errorOptions public property
The default options for the error tags. The parameter passed to error() will be merged with this property when rendering the error tag. The following special options are recognized:
-
tag
: the tag name of the container element. Defaults todiv
. Setting it tofalse
will not render a container tag. See also yii\helpers\Html::tag(). -
encode
: whether to encode the error output. Defaults totrue
.
If you set a custom id
for the error element, you may need to adjust the $selectors accordingly.
See also yii\helpers\Html::renderTagAttributes() for details on how attributes are being rendered.
public array $errorOptions = ['class' => 'help-block']
Please login to continue.