Sedang Disiapkan

222224 Retirement Calculator in PHP

NEED BY TUESDAY (5/13) NIGHT (cst time)! (perhaps later if this is impossible)

I need an online retirement calculator in PHP. In a nutshell, the calculator will collect data, record it to a MySQL database and make some calculations based on the data. The calculations will actually be MUCH less than typical retirement calcs and there's no need to display any year-by-year spending results or other data (at this time). Generally, the calc should determine the TOTAL amount of money needed to support retirement (+ a fudge of 20%) vs. the total amount anticipated to be available based on applicant's current saving, etc. Once I have those two numbers, I'll set up a score of sorts.

Please see my note about adapting an existing open source script below: ([url removed, login to view])

Here's the process:

1. Form Fields: (as found at [url removed, login to view] (which is roughly how form should appear)

First Name ($firstname)

Last Name ($lastname)

Email Address ($email)

Phone Number ($phone)

Extension ($extension) *no error checking*

Pass Code ($passcode)

Resident Zip Code ($zipcode)

Current Age

Age you wish to retire

Life Expectancy

Current Income

Current Savings Balance

Current Annual Savings for Retirement

Increase Savings to account for inflation (Y/N)

Avg Rate of return UP TO retirement

Avg Rate of return DURING retirement

Avg Rate of inflation

Annual retirement income from other sources

What age does this start?

Annual yearly increase in % of this income?

Amount of expected future retirement assets?

When will said assets be received?

Do you wish to increase income to account for inflation? (Y/N)

2. Error Checking and Pass Code checking (use PHP error checking or javascript alerts)

+ All form fields except extension should be checked for existence

+ Numeric form fields (excluding phone & ext) should be checked as numbers

+ Pass Code needs to be checked against validity in MySQL DB using the following code:

************CODE STARTS*****************

$table_name ="advisor_pass";


<AT SIGN>mysql_select_db($database) or die( "Unable to find Retire Wealthy ADVISOR database.");

// Check for existance of passcode

$count = mysql_num_rows(mysql_query("SELECT * FROM $table_name WHERE passcode = '$passcode'"));

if ($count == 1)


$query="SELECT * FROM $table_name WHERE passcode = '$passcode'";

$result = mysql_query($query) or die('Error, query failed');

//get results associated with that Pass Code, assign variables

while ($row =mysql_fetch_array($result)){

$advisorID= $row['ID'];

$advisorNAME= $row['name'];}




*************END OF CODE**************

3. Process Data

Unfortunately, I don't have the formula. If you examine the form at [url removed, login to view] there are detailed explanations of how each number is applied -- however the form does NOT generate detailed results. Also there are dozens of financial calcs on the net. I'm actually somewhat flexible on the fields/formula.

A good guide for this is in the FREE script: [url removed, login to view]

IF YOU CAN ADAPT THIS SCRIPT ALL THE BETTER. The problem with this script is that it doesn't currently account for current savings and yearly savings. It generates the money needed but doesn't figure out what the applicant is currently savings. We need to figure out if they will meet their goal or will need help.

4. Leave me clean variables so I can record A) the applicant's original form field entries in a MySQL DB, B) the money they will have based on their current savings (one variable) and C) the money they need to have (+ 20%) (one variable). D) I'll write a formula to compare the two and generate a score.



1. It's quite possible the script will have to be adjusted or slightly altered after completion. Work minor adjustments into your price. Major ones we can negotiate.

2. I'm not supplying the formula but will continue to look. If you find a DIFFERENT but similar formula (asking for different but similar form fields) I will strongly consider it. Time is of the essence.

3. I'm attaching my adaptation of the free script mentioned. This was going to work for me until I realized that it did not account for retirement savings (duh). Also, I don't need the detailed printout at the end, and the whole emphasis on reduced income needed for retirement is not necessary.

4. I'm okay at PHP but I will need some explanations. The important things is that I have easy access to variables for placement into a DB.

5. Links to similar scripts you've done are appreciated. If you've done a Retirement Calc for someone else with different fields, I'm willing to consider it.

Kemahiran: Semua Boleh, CSS, MySQL, PHP

Lihat lebih lanjut: write scripts online, write javascript code online, script advisor, php mysql online help, source life, online code major, look php, javascript vs, in php, id life, write code php, get phone number support, free money sources, financial data calculator, email support number, code javascript money online, check javascript code online, calculator html javascript code, zip form online, write javascript online, online financial advisor, find current address, financial advisor online, write php online, php calculator scripts

Tentang Majikan:
( 4 ulasan ) Chicago,

ID Projek: #1968459