https://jsfiddle.net/qz8hL574/1/
for (var key in table) {
if (table.hasOwnProperty(key)) {
$('<div class="element"></div>').appendTo('#list');
document.getElementsByClassName("element")[key].innerHTML = table[key].symbol;
}
}
This snippet demonstrates how to populate a div using JavaScript.
The provided code functions as expected, producing a screenshot similar to http://prntscr.com/knwyh0 It appears that only the last element is visible, even though all divs are filled with correct values. Applying a z-index of 100 to a specific element doesn't result in it being displayed prominently. A desired layout involves having them aligned vertically at the center. Any suggestions on resolving this issue?