Reputation: 43
I am using EricHynds Multiselect filters plugin. It filters the values present in the dropdown when we enter some text in input field. But I want to send ajax request when user enters some text in input I can handle Ajax data easily but I am unable to fetch input field value.
Till now I am writing following code:
$(".container_filter").multiselect({}).multiselectfilter({
filter: function(event, matches){
console.log(event.currentTarget);
}
});
But from it I am unable to get value of input field.
My console.log(event.currentTarget)
returns <input type="search" placeholder="Enter keywords">
.
When I use console.log(event.currentTarget.val())
then it returns undefined
.
Upvotes: 2
Views: 1002
Reputation: 2708
According to me
console.log(event.currentTarget.value)
will work fine.
As javascript is working in EricHynds plugin.
Upvotes: 3