Convert c:list to an html list including an optional wrapper div/span if the list has a title