Question
Please write in JavaScript and HTML, with each question being a separate HTML page. Thank you. :D 1. Create a JavaScript program that reads JSON
Please write in JavaScript and HTML, with each question being a separate HTML page. Thank you. :D
1. Create a JavaScript program that reads JSON data from inside the file and displays the data on a web page. You should display this information somewhere in the HTML file visibly.
2. Create another JavaScript program that reads a JSON array from inside the file and displays them inside of a table. You should have at least 5 objects inside of the array, here is a sample array:
var jsonData = {
"example": [
{ "firstName":"FirstStudent1", "lastName":"LastStudent1" },
{ "firstName":"FirstStudent2", "lastName":"LastStudent2" },
{ "firstName":"FirstStudent3", "lastName":"LastStudent3" }
]
};
For this problem, your JavaScript should be in an external .js file, linked to your .html file.
3. Create an HTML file with JavaScript that has a class with a constructor. You should then create another function in that class that will print out somewhere on the HTML file, similar to the first example done in class.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started