I would like to be able to detect when the selected value of dropdown has changed using jQuery. The selected value of the dropdown is changed by other JavaScript, so I want to be able to catch this event.
I can see the dropdown changing, however the following code does not capture the event correctly. Does the change
event only capture the event when it is performed by the user and not other code?
$('select[name=b_country]').live('change', function() {
alert('the country dropdown has changed');
});
<select name="b_country" style="display: block;">