I’m using http://bassistance.de/jquery-plugins/jquery-plugin-validation/ for validation in my MVC app.
I have a repeating text input (bound using knockout) that is marked as required:
<form id="myForm" class="validate_form" method="get" action="">
<input type="text" class="required error txtOrder" maxlength="4000"
placeholder="Please enter your order..." data-bind="{ attr: {
id: viewModel.orderID }}" />
- There are 10 rows.
- I click “Save” and it blocks the form, saying that the field is required.
- I enter some text in the field next to the error message, leaving the other 9 rows empty.
- I click “Save” and the validator thinks that the form is now valid and allows the form to be submitted.
What am I doing wrong? Or does the jQuery validator not work with knockout? If so, is there a professional-looking jQuery plugin that will work with knockout?
Thank you for your assistance.
inputshown has nonamewhich is required to submit field and validator plugin usesnameto identify fields also