Code:
var orgTotal = (Ototal + Etotal);
// the var on the next line is BOGUS...you can't use var for the same name twice
// but in any case GET RID of this next line COMPLETELY:
/* var orgTotal = orgTotal.toFixed(2); */
grandTotal = Number(schoolTotal + orgTotal);
if(isNaN(grandTotal)) {
grandTotal = "";
} else {
grandTotal = grandTotal.toFixed(2);
}
if(isNaN(orgTotal)) {
orgTotal = "";
} else {
orgTotal = orgTotal.toFixed(2);
}
document.getElementById("orgTotal").innerHTML = orgTotal;
document.getElementById(orgType + 'total').innerHTML = total;
document.getElementById(orgType + 'active').innerHTML = active;
document.getElementById("schoolTotal").innerHTML = schoolTotal;
// document.getElementById("grandTotal").innerHTML = schoolTotal; ??? SURELY THIS IS WRONG ???
// shouldn't it be
document.getElementById("schoolTotal").innerHTML = grandTotal;
red means kill it
blue means add it