how to drag and drop and replace element from one div to another div code example
Example: jquery move element to another without losing events
$('#element_to_move').appendTo('#PARENT_at_destination');
$('#element_to_move').appendTo('#PARENT_at_destination');