js - how to output values from function into HTML table
问题 I've created a calculator to show repayments over the term of the loan. I've managed to calculate each months payment, interest, remaining loan but I'm trying to output this into a table. The columns will be a fixed number (5) but the rows should dynamically update based on the number of months. I've seen a few similar posts but can't get it to work for my code. Code below and in jsfiddle HTML <div class="mortgageInput"> <form method="POST" name="calc" onclick="validateForm();repayment()