views:

108

answers:

1

I have two dropdown list (let's say there ids are ddl1 and ddl2). How can I set dropdown list 1 (ddl1) equals dropdown list 2 (ddl2) in jQuery?

Something like: $('#ddl1').val()=$('#ddl2).val()

Thanks in advance.

+4  A: 

Like this:

$('#ddl1').val($('#ddl2').val());
Peter