jQuery - is it possible to dynamically wrap a bunch of generated <li>
elements (fetched via JSON) appended to a div id with <ol>
, for example?
I know of the wrap()
function, but that seems to do it for each element of the li. Applying the prepend("<ol>")
automatically closes the tag before the each / append()
loop goes through