Topic: select drop down won't validate using html 5 required
ayescas priority asked 3 years ago
Hello,
How can I validate a select drop-down. The following select won't validate, it will always return true when null.
<select class="mdb-select md-form md-outline colorful-select dropdown-primary"
required
id="g_type"
name="g_type">
<option value="" disabled selected>Request Type:</option>
<option value="Interpretation">Interpretation</option>
<option value="Translation">Translation</option>
</select>
<label class="mdb-main-label">Request Type</label>
</div>
Marcin Luczak staff answered 3 years ago
Hi,
For non Material Select validation please see my snippet and also check forms validation documentation. For Material Select validation please see its own validation example.
Regards, Marcin
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- ForumUser: Priority
- Premium support: Yes
- Technology: MDB jQuery
- MDB Version: 4.19.1
- Device: MacBookBook Pro
- Browser: safari
- OS: OSX
- Provided sample code: No
- Provided link: No