I have included a fiddle here: jsfiddle.net/LgE3N
I have a series of arrays in a javascript file that I need to import into an web page. I seem to be able to work with the arrays in the script and have been able to output totals of numbers into the page, however, I do not seem to be able to figure out how to print the entire list into the web page.
window.onload = function ()
{
$("#contributions").html (totalContributions.toFixed(2));
$("#amount").html (totalContributors);
var dateString = "";
for (var j = 0; j < date.length; j++)
{
dateString += date[j];
$("#dateArray").html (dateString);
}
}
.
<div id="data_list">
<table rules="rows" cellspacing='0'>
<thead>
<tr>
<th>Date</th>
<th>Amount</th>
<th>First Name</th>
<th>Last Name</th>
<th>Address</th>
</tr>
<td>
<p>dateArray</p>
<id "dateArray">
</td>
<td>
<p>amountArray</p>
</td>
<td>
<id "dateArray">is not valid html. Change it to<div id="dateArray"></div>