Is there a way to give generated divs the same name so I can markup them easily?
$.getJSON("data/reviews.json", function(data){
for(var i=0; i<data.length; i++)
{
var review = sym.createChildSymbol("Template", "content");
review.$("title").html( data[i].reviewer );
review.$("review").html( data[i].review );
}
The code is functional, but it displays my objects one beneath the other, which isn't visually appealing. I attempted using the following code snippet, but it seems that my object consists of 5 different divs...
$( "div:last" ).addClass( "reviewdiv" );
Any suggestions on how to improve this layout?
This is the current HTML output:
<div id="Stage_content" class="Stage_content_id content" style="position: absolute; margin: 0px; left: 0px; top: 3091px; width: 100%; height: 758px; right: auto; bottom: auto; overflow: visible; border: 5px none rgba(63, 115, 128, 0.596078); background-color: rgb(240, 240, 240); -webkit-tap-highlight-color: rgba(0, 0, 0, 0);">
<div id="eid_1390419617256" style="position: relative; -webkit-transform: translateZ(0); min-width: 0px; overflow: hidden; height: 210px; max-width: 295px; width: 300px;">
... some more div id="eid_*****"...
</div>