Question: This javacode is not working I don't know what's wrong with it. im attaching a picture of expected output. body { background-color: #454F8C; font-family: arial;

This javacode is not working I don't know what's wrong with it. im attaching a picture of expected output.

body { background-color: #454F8C; font-family: arial; color: #454F8C; }

#contentwrap { background: #F4F5E7; border: 8px #FF9E01 solid; padding: 20px; width: 600px; margin: 20px auto 0px auto; border-radius: 25px; text-align: center; }

#heading { font-size: 2.2em; border-bottom: 6px #484452 double; padding: 10px 0px 10px 0px; }

.formtext { margin-top: 8px; width: 200px; }

.formfield { padding: 4px; border: 2px darkred solid; font-size: 1.2em; color: red; font-weight: bold; }

#calcbutton { background: #003366; color: #FFFFFF; padding: 5px 0px 5px 0px; width: 150px; border: 3px #CCCC99 solid; border-radius: 25px; cursor: pointer; font-size: 1.1em; }

#calcbutton:hover { background: #CCCCCC; color: #003366; border: 3px #003366 solid; }

$(document).ready( function() {

$("#calcbutton").on( "click", function() { var name = $("#ename").val() ); var budget = parseFloat( $("#ebudget").val() ); var food = parseFloat( $("#efood").val() ); var gas = parseFloat( $("#egas").val() ); var entertainment = parseFloat( $("#eentertainment").val() ); var totalexpenses = (food + gas + entertainment); var moneyleftover = (budget - totalexpenses); var msg = "

Name is " + name + "

"; var msg = "

Monthly budget is $" + budget + "

"; var msg = "

Food expense is $" + food + "

"; var msg = "

Gas expense is $" + gas + "

"; var msg = "

Entertainment expense is $" + entertainment + "

"; var msg = "

Total money left after expenses is $" + moneyleftover + "

"; $("#output").html( msg ); } ); } ); // document.ready

Household Budget Calculator

Enter name
Enter monthly budget
Enter monthly food expense
Enter monthly gas expense
Enter monthly entertainment expense

This javacode is not working I don't know what's wrong with it.

Household Budget Calculator Enter name Jared Ganson Enter monthly budget 500.00 Enter monthly food expense 250.00 Enter monthly gas expense 180.00 Enter monthly entertainment expense 150.00 Calculate Budget Name is Jared Ganson Monthly budget is $500.00 Food expense is $250.00 Gas expense is $180.00 Entertainment expense is $150.00 Total money left after expenses is $-80.00 You DO NOT have enough money to cover your expenses

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!