COMING_TRUTH
New Member
I am using a button to create a new div every time the button is clicked. Ultimately, I am going to need a unique ID for each one of these new divs, but for now I need to change the CSS for certain child elements. Instead of using pseudo-class expressions, is there a way, using jQuery, that I can assign a unique ID number, and use that ID to alter the CSS of the new divs that are created?Here is my code:\[code\] $("button[type=email]").click(function(){ $("<ul />") .html('<div id="friend"><b>Friend Name<b><a class="close closethis tooltip" data-tooltip="Remove persona"><i class="icon-remove"></i></a></div>') .appendTo("#drag-area");});\[/code\]