Successfully reported this slideshow.
Your SlideShare is downloading. ×

Develop- test- and validate an HTML document that has checkboxes for a.docx

Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad
Ad

Check these out next

1 of 1 Ad

Develop- test- and validate an HTML document that has checkboxes for a.docx

Download to read offline

Develop, test, and validate an HTML document that has checkboxes for apple ( 59 cents each), orange ( 49 cents each), and banana ( 39 cents each), along with a button. Each of the checkboxes should have its own onclick event handler. These handlers must add the cost of their fruit to a total cost. An event handler for the button must produce an alert window with the message , where is the total cost of the chosen fruit, including 5 percent sales tax. This handler must return false ( to avoid actual submission of the form data).
Solution

Top of Form
Bottom of Form
Apples Bananas Oranges // total.js // This script illustrates using the focus event // to prevent the user from changing a text field var totalCost = 0; function total() { //Which buttons are checked plus costs var dom = document.getElementById(\"myForm\"); for(var index = 0; index
.

Develop, test, and validate an HTML document that has checkboxes for apple ( 59 cents each), orange ( 49 cents each), and banana ( 39 cents each), along with a button. Each of the checkboxes should have its own onclick event handler. These handlers must add the cost of their fruit to a total cost. An event handler for the button must produce an alert window with the message , where is the total cost of the chosen fruit, including 5 percent sales tax. This handler must return false ( to avoid actual submission of the form data).
Solution

Top of Form
Bottom of Form
Apples Bananas Oranges // total.js // This script illustrates using the focus event // to prevent the user from changing a text field var totalCost = 0; function total() { //Which buttons are checked plus costs var dom = document.getElementById(\"myForm\"); for(var index = 0; index
.

Advertisement
Advertisement

More Related Content

More from rtodd615 (20)

Recently uploaded (20)

Advertisement

Develop- test- and validate an HTML document that has checkboxes for a.docx

  1. 1. Develop, test, and validate an HTML document that has checkboxes for apple ( 59 cents each), orange ( 49 cents each), and banana ( 39 cents each), along with a button. Each of the checkboxes should have its own onclick event handler. These handlers must add the cost of their fruit to a total cost. An event handler for the button must produce an alert window with the message , where is the total cost of the chosen fruit, including 5 percent sales tax. This handler must return false ( to avoid actual submission of the form data). Solution Apples Bananas Oranges // total.js // This script illustrates using the focus event // to prevent the user from changing a text field var totalCost = 0; function total() { //Which buttons are checked plus costs var dom = document.getElementById("myForm"); for(var index = 0; index

×