Hi,
I am using Phlacon v3. I would like to set default focus to be on the first field of my Volt form. I have tried both autofocus
and tabindex=1
in the volt view but nothing seems to make any difference. I am using Form. Tried adding these clauses to the form too but nothing seems to be working. It always focuses on a field with select
list which is 6th field on the form.
Code below:
<div class="col-sm-3">
{{ form.render("care_id", ["class" : formFieldClass, "id" : "fieldCareId", 'autofocus' : 'autofocus']) }}
</div>
OR
<div class="col-sm-3">
{{ form.render("care_id", ["class" : formFieldClass, "id" : "fieldCareId", 'tabindex' : '1']) }}
</div>
Not sure what's going on.
Thanks, Amal