jqBootstrapValidation icon indicating copy to clipboard operation
jqBootstrapValidation copied to clipboard

jqbootstrapValidation data-validation not working

Open arun2206 opened this issue 10 years ago • 2 comments

<div class="col-md-2 col-lg-2 min-max-column">Minimum </div>
<div class="col-md-3 col-lg-3 add-subtract-min-value controls">
  <button class="subtract-minimum-value">-</button>
  <input type="text" class="minimum-value" value="<%- questionData.numberProperties.minValue || 0 %>" data-validation-regex-regex="[-]?[0-9]+" data-validation-regex-message="Must be a numeric value" required />
  <button class="add-minimum-value">+</button>
</div>

<div class="col-md-4 col-lg-4">
  <input type="text" id="minimum-value-label" value = "<%- questionData.numberProperties.minLabelText || '' %>" class="minimum-label label-text" placeholder="Minimum Value Label" style="width: 200px" /> 
</div>

<div class="col-md-3 col-lg-3 characters-typed-info">
  <label> ( <span class="minimum-value-label-length not-required blue-text inline-element description-length"></span> / 30 characters) </label>
</div>
<div class="col-md-2 col-lg-2 min-max-column">Maximum </div>

<div class="col-md-3 col-lg-3 add-subtract-max-value controls">
  <button class="subtract-maximum-value">-</button>
  <input type="text" class="maximum-value" value="<%- questionData.numberProperties.maxValue || 5 %>" required data-validation-greater-greater="minimum-value"
         data-validation-greater-message="Must be greater than minimum value"/>
  <button class="add-maximum-value">+</button>
  <div class="max-min-error-block help-block" style="display: none;">Must be greater than minimum value</div>
</div>

<div class="col-md-4 col-lg-4">
  <input type="text" id="maximum-value-label" value = "<%- questionData.numberProperties.maxLabelText || '' %>" class="maximum-label label-text" placeholder="Maximum Value Label" style="width: 200px" />
</div>

<div class="col-md-3 col-lg-3 characters-typed-info">
  <label> ( <span class="maximum-value-label-length not-required blue-text inline-element description-length"></span> / 30 characters) </label>
</div>

I use two blocks of control-groups. I have attached the screens reqd.

I can't use the followed by the help-block div to get the validation error as the CSS doesn't allow.

The minimum and maximum has to be validated such that the minimum must be less then the maximum value field.

Can anybody please help ? jqbootstrap_working

arun2206 avatar Jul 30 '15 14:07 arun2206

For Bootstrap 3.X use this fork

hackhowtofaq avatar Jan 31 '16 08:01 hackhowtofaq

data-validation-required-message does not work too! Not support 3.X?

Thyiad avatar Feb 27 '16 15:02 Thyiad