0

I've looked over some documentation on the jQuery validation plugin website as well as did a search on this site for a few questions that might be able to render me an answer but I have not found one that has suited me as a solution. What I'm trying to do is get my select tag to validate as an option is needed to be selected to pass the validation of the element.

As of right now with my other form fields validating I am in limbo wit the lone element not validating. I found that adding required to the select element should work but it is not.

Is there anything else to try?

<select class="form-control chosen-select" required data-placeholder="User Status" name="user_status" style="display: none;">
    <option value=""></option>
    <option value="1">Active</option>
    <option value="2">Inactive</option>
    <option value="3">Suspended</option>
    <option value="4">Banned</option>
    <option value="5">Deleted</option>
</select>
Diodeus - James MacFarlane
  • 112,730
  • 33
  • 157
  • 176
user2576961
  • 405
  • 1
  • 10
  • 26
  • http://stackoverflow.com/questions/11039658/how-to-check-whether-a-select-box-is-empty-using-jquery-javascript – Hackerman Jan 24 '14 at 20:50
  • Any idea with using jQuery's validation plugin. – user2576961 Jan 24 '14 at 21:40
  • What do you mean by the element “not validating”, and how do you expect the user to select any option when you have set `display: none` on the entire `select` element? – Jukka K. Korpela Jan 24 '14 at 21:50
  • The display none was something that a chosen js plugin does to select tags. What I meant to not validating was that I want it to show an error when a selection is not made to the select statement. – user2576961 Jan 24 '14 at 22:26

0 Answers0