我在我的項目中使用引導和淘汰賽。在此之前,我正在使用基因敲除驗證,但現在我必須使用jquery驗證引擎和基因敲除視圖模型和引導程序html。假設這是我的HTMLJQuery驗證引擎與淘汰賽和引導
<fieldset>
<div class="form-group">
<label for="name">Name</label>
<input type="text" class="form-control placeholder" id="personName" placeholder="Your name" data-bind="value: name" />
</div>
<div class="form-group">
<label for="email">Email address</label>
<input type="email" class="form-control placeholder" id="personEmail" placeholder="Your email" data-original-title="Your activation email will be sent to this address." data-bind="value: email, event: { change: checkDuplicateEmail }" />
</div>
<div class="form-group">
<label for="password">Password</label>
<input type="password" class="form-control placeholder" id="password" placeholder="Password" data-bind="value: password" />
</div>
<div class="form-group">
<label for="confirmPassword">Repeat Password</label>
<input type="password" class="form-control placeholder" id="repeatPassword" placeholder="Repeat password" data-bind="value: confirmPassword, event: { change: matchPassword }" />
</div>
<div class="form-group">
<label for="companyName">Company Name</label>
<input type="text" class="form-control placeholder" id="companyName" placeholder="Your company name" data-bind="value: company" />
</div>
<div class="form-group">
<label for="country">Country</label>
<select class="form-control placeholder" id="country" data-bind="options: availableCountries, value: selectedCountry, optionsCaption: 'Country'"></select>
</div>
<button id="signupuser" type="button" data-bind="click: signup" class="btn btn-primary btn-block">Create Free Account</button>
</fieldset>
現在我感到困惑如何使用jQuery Validation Engine Plugin與我上面的代碼。
你混淆哪一部分?你試過什麼了?你的視圖模型是怎樣的?你想驗證什麼? – nemesv
我很困惑,如何使用這個插件,因爲我的標記中沒有'form'元素。 – Ancient
那你爲什麼不把'fieldset'換成'form'呢? – nemesv