Hands-On Project 1-3 In this project, you will explore how to write text to a specific element in your web page in response to the onclick event handler. To complete the exercise, you will apply the following JavaScript expression: document.getElementById('id').innerHTML = 'text'; where id is the value of the id attribute for the page element and text is the text of the content to be written into the element. You will use this expression to enhance a web form by displaying the message “Thank you for your order” when the user clicks the Submit button. Figure 1-25 shows the completed web page. Do the following: 1. Use your code editor to open project01-03_txt.html from the HandsOnProject_01 folder. Enter your name and the date in the comment section of the document and save it as project01-03.html. 2. Scroll down to the bottom of the file and locate the input element for the Submit button. 3. Add an onclick event handler to the tag that changes the innerHTML value of the page element with the id “submitMsg” to the text message Thank you for your order. (Note: The entire JavaScript expression should be enclosed within a set of double quotation marks, but the id and the text message should be enclosed within single quotes.) 4. Save your changes to the file and then open project01-03.html in your web browser. Click the Submit button and verify that the text “Thank you for your order” appears on the bottom of the page.

Information Technology Project Management
9th Edition
ISBN:9781337101356
Author:Kathy Schwalbe
Publisher:Kathy Schwalbe
Chapter10: Project Communications Management
Section: Chapter Questions
Problem 10QQ
icon
Related questions
Question

Hands-On Project 1-3
In this project, you will explore how to write text to a specific element in your web page in response to the
onclick event handler. To complete the exercise, you will apply the following JavaScript expression:
document.getElementById('id').innerHTML = 'text';
where id is the value of the id attribute for the page element and text is the text of the content to be written
into the element. You will use this expression to enhance a web form by displaying the message “Thank you for
your order” when the user clicks the Submit button. Figure 1-25 shows the completed web page.
Do the following:
1. Use your code editor to open project01-03_txt.html from the HandsOnProject_01 folder. Enter your name and the date in the comment section of the document and save it as project01-03.html.
2. Scroll down to the bottom of the file and locate the input element for the Submit button.
3. Add an onclick event handler to the <input> tag that changes the innerHTML value of the page element with the id “submitMsg” to the text message Thank you for your order. (Note: The entire JavaScript expression should be enclosed within a set of double quotation marks, but the id and the text message should be enclosed within single quotes.)
4. Save your changes to the file and then open project01-03.html in your web browser. Click the Submit button and verify that the text “Thank you for your order” appears on the bottom of the page.

Hands-on Project 1-3
Order Form
Contact Information
Name
Email
Phone
Reservation Information
-Pickup date-
January
2022
Figure 1-25 Completed Project 1-3
-Dropoff date
January
Submit
Thank you for your order
2022
Transcribed Image Text:Hands-on Project 1-3 Order Form Contact Information Name Email Phone Reservation Information -Pickup date- January 2022 Figure 1-25 Completed Project 1-3 -Dropoff date January Submit Thank you for your order 2022
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 8 steps with 6 images

Blurred answer
Knowledge Booster
JQuery and Javascript
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Information Technology Project Management
Information Technology Project Management
Computer Science
ISBN:
9781337101356
Author:
Kathy Schwalbe
Publisher:
Cengage Learning
Principles of Information Systems (MindTap Course…
Principles of Information Systems (MindTap Course…
Computer Science
ISBN:
9781285867168
Author:
Ralph Stair, George Reynolds
Publisher:
Cengage Learning