How to make selector dynamic

How to make selector dynamic

Hi Friends

I am very new to jquery and stuck with one problem. 

problem is I have two dropdowns and onchange event of first drop down i am populating options of second dropdown. then I have extended this functionality with add more option where i am adding both the drop downs again. 

But the problem is in ajax success method m appending options to specific select box how can I make them dynamic??