I created a elemento
with JavaScript:
$("<div />").addClass("placeholder").appendTo(element);
But I can not give attributes to it, how can I do this? I tried the following code, but it does not work:
$(document).ready(function(){
$(".placeholder").addClass("fg-red");
});
If I create it with HTML it works, however when I create with JavaScript the attempt to add attributes does not work