$(function () { var a = 0; $("#body > .widget-slides").each(function () { var b = "widget-slides-" + a; $(this).attr("id", b); for (var c = $('
').appendTo(this), d = $(' ').appendTo(c), e = 1; e <= $(".widget-body .list-item", this).length; e++) d.append('