I usually use this way
<div class="hcs-inner-col2"><?= $this->formInput($this->form->get('accountname')); ?></div>
So this way, it won’t add input-error to input element itself?
What’s the differences between $this->formRow() and $this->formInput().
By the way, I usually use the form like follow to built my form elment:
'name' => 'servername',
'type' => Text::class,
'attributes' => [
'id' => 'servername',
'placeholder' => 'pls add a servername',
It is possible to add errorclass here? ok forget about it, I can change the invalid class to input-error.
So it is possible to show the input-error when I use this way
<div class="hcs-col2"><?= $this->formInput($this->form->get('servername')); ?></div>