Hello
On this page, I have a filtering system:
http://igastaging.wpengine.com/recipes/test-page
I want to pickup the value selected from any of the dropdowns, and I have an onchange function in jQuery. If you open the Chrome Inspector -> Console, and try to change the first dropdown, the value shows. For example, Desserts.
However, subsequently, the onchange function does not fire. What I mean is, on the second time, and on any other dropdown, the onchange function will not fire once it gets a value.
Here is the jQuery:
` $(‘select[name =”_sfm_assigned_meal_type[]”]’).change(function() {
var val = this.value;
console.log(“_sfm_assigned_meal_type[]: ” +val);
});
$(‘select[name =”_sfm_assigned_dietary_requirements[]”]’).change(function() {
var val = this.value;
console.log(“_sfm_assigned_dietary_requirements[]: ” + val);
});
$(‘select[name =”_sfm_assigned_ingredients[]”]’).change(function() {
var val = this.value;
console.log(“_sfm_assigned_ingredients[]: ” + val);
});`
Please see image: