I have a html element with a large collection of unordered lists contained within it. I need to clone this element to place elsewhere on the page with different styles added, this is simple enough using JQuery.
$("#MainConfig").clone(false).appendTo($("#smallConfig"));
The problem, however is that all the lists and thier associated list items have Ids and clone duplicates them. Is there an easy way to replace all these duplicate id's using JQuery before appending?