I’ve taken this and created a jsfiddle for my code which can be found here:
I was inspired to use the Switch Loop and created the code with the help of this tutorial:
I’d like to have the customer see results in the following format:
Example of Bonded Title Service:
You chose the service of : Service Name
Your Service Fee is $0.00
Your Bond Value is $0.00
Your Bonding Fee is $0.00
Your Bonding Overage Fee is $0.00
Your Tax, Title and Licensing Fee is $0.00
The total estimated cost of your service is $0.00
In the console, it currently shows the actual view I’d like to present to customers for inputting vehicle value and selecting their service. When they’ve done so, I’d like to have the results, as shown in the example above, presented in the
<div id="results"> </div> area as laid out in the html so it shows up just under the input area.
So, of course, the “Switch” is meant to test cases against each service_prices name and then output the estimate statements for each service. My issue is that when I use this “var service = service_prices” on line 52 of the js code the console gives a black background and outputs the default case message of the switch, thus totally bypassing the needed input area created by html.
Let me warn you, all this is something I’m learning, so I KNOW it is far from perfect, but I’ve attempted to get it to a point where I could show my intention and get someone to point me in the right directions. Any and all help is deeply appreciated.