The thing I want to achieve is whenever the dropdown is changed I want the value of the dropdown before change. I am using 1.3.2 version of jQuer
var last_value; var current_value; $(document).on("click","select",function(){ last_value = $(this).val(); }).on("change","select",function(){ current_value = $(this).val(); console.log('last value - '+last_value); console.log('current value - '+current_value); });
Stack Overflow My Question