require_once("/home/users/web/b1565/pow.daviddude/htdocs/functions.php"); do_header("Loan Calculator", "menu.txt"); $P = $_POST["P"]; $I = $_POST["I"]; $T = $_POST["T"]; $X = $_POST["X"]; if($P == "" || !IS_NUMERIC($P)) $P = 25000; if($I == "" || !IS_NUMERIC($I) || $I < 1) $I = 6.54; if($T == "" || !IS_INT(intval($T))) $T = 60; if($X == "" || !IS_NUMERIC($X)) $X = 15.25; $R = $I / 1200; ?>
I accept NO responsibility for anyone's use of this loan calculator. It's here purely for my unlimited enjoyment. Anyone choosing to use it accepts ALL responsibility for it's use. In other words, if you win the lottery and base your investment decisions on this calculator I can't be held liable if the calculations are completely wrong. If you give me $1 mil or so of your winnings, I may reconsider. :-)
Monthly Payment: $ echo number_format($payment, 2, '.', ','); ?>
With extra: $ echo number_format($payment+$X, 2, '.', ','); ?>
Payment Number |
Beginning Balance |
Payment | Extra Amount |
Principal | Interest | Ending Balance |
---|---|---|---|---|---|---|
$pmt_num | \n"; $pmt_num++; echo "\t\t$".number_format($balance, 2, '.', ',')." | \n"; $interest = round($balance * $R, 2); if($balance < $payment + $X) $payment = $balance + $interest - $X; echo "\t\t$".number_format($payment, 2, '.', ',')." | \n"; echo "\t\t$".number_format($X, 2, '.', ',')." | \n"; $total_payments = $total_payments + $payment + $X; $principal = round($payment - $interest, 2); $balance = round($balance - $principal - $X, 2); echo "\t\t$".number_format($principal, 2, '.', ',')." | \n"; echo "\t\t$".number_format($interest, 2, '.', ',')." | \n"; $total_interest = $total_interest + $interest; echo "\t\t$".number_format($balance, 2, '.', ',')." | \n"; echo "\t
Total of payments: $ echo number_format($total_payments, 2, '.', ','); ?>
Total interest: $ echo number_format($total_interest, 2, '.', ','); ?>
do_footer(); ?>