I use two select_advanced fields and when I select an option in the first dropdown I want to disabled it from the second dropdown.
I use the following code. The disabled attribute added successfully but the option isn't disabled.
(function($) {
$('#_language_pairs_from').on('change', function() {
var selectVal = $(this).val();
$('#_language_pairs_to option[value="'+selectVal+'"]').prop('disabled', true);
});
})( jQuery );