I have been creating a form with lots of <input type="checkbox">
for search and filter functionality. Please find the code below;
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" name="type" value="1" id="type1">
<label class="custom-control-label" for="type1">Filter Sub Item</label>
</div>
But when the page renders in the browser the DOM is appended with a new hidden field for each <input type="checkbox">
<input type="hidden" name="_type" value="on">
I am using Boostrap CSS library for the form design. How can I stop this from auto generating the hidden fields in the form.
When I submit the form with method="get" these hidden values are appearing in the browser address bar.
Aucun commentaire:
Enregistrer un commentaire