The for loop I have is functioning properly:
<div id="page1div"></div>
<script>
list = " ";
for (var i = 0 ; i < length ; i++)
{
list = "<h1 class='entriesdisplayed'>" +
item(i) +
"<span class='bolditalic'> x " +
description(i) +
" </span>" +
"</h1>" +
list;
}
$("#page1div").html(list);
</script>
While the above code accurately displays elements of the array, I want to emphasize description(i)
in bold and italic. The current structure has description(i)
wrapped in a span class="bolditalic"
.
In my CSS3 file, I've defined this style:
.bolditalic
{
font: bold italic;
}