I’ve been looking and looking for an error here as I can’t clear the input #keywordsearch when clicking on the reset button in my HTML. However, I can’t find anything – can you see an issue?
Here’s my JS:
$('#dirreset').click(function() {
$('#fatform option').each(function(index) {
$(this).removeAttr("selected");
});
$('#keywordsearch').val('');
});
Thanks for any help, it’s driving me a bit mad!
Osu
Clicking Reset button, the entries are reset to the default values. And
asfis your default value, so it wont clear, So changeto
Demo: jsFiddle