3
Hello, how can I reset a select field?
<label for="IDSelect">Campo</label>
<select data-live-search="true" title="--" name="NAMESelect" id="IDSelect">
<option value="1">Valor 1</option>
<option value="2">Valor 2</option>
</select>
Note that the default value when loading the page is "--", I want that after selecting an option and submitting this form (submerged with jquery), return to the default value "--"
When you write that "the default value when loading the page is "--"" gives me the idea that you are using a plugin for selects. That’s the case? which one?
– Sergio
I’m wearing bootstrap
– Marcelo
Can you mount a jsFiddle with an example? Boostrap is using the title attribute as an option?
– Sergio
can, wait a few minutes I’m riding, and I don’t use very well
– Marcelo
Okay, check it out: https://jsfiddle.net/t0u1j6L8/1/
– Marcelo