Home work question. (html/java) should be possible for someone to select the user by gender. You should be using the select element within the id selectgender to be able to do this .The select element should also be an option to select "All" genders.  This filter should combine appropriately with the year of birth filter as well. For example,if male is chosen then it should show all male users. It should be possible for the someone to select a range of birth years, When they do this the table should update to show only the users for that range of years. For example if the years ranges are 2000 -2002 it should be only showing users in that year range. I will include the java, json and html below . Any help will be great. JSON [ { "users": [ { "userId": 1, "firstName": "Krish", "lastName": "Lee", "Gender":"Male", "year of birth":2000 }, { "userId": 2, "firstName": "racks", "lastName": "jacson", "Gender":"Female", "year of birth":1999 { "userId": 3, "firstName": "denial", "lastName": "roast", "Gender":"Male", "year of birth":2002 }, { "userId": 4, "firstName": "devid", "lastName": "neo", "Gender":"Non binary", "year of birth":1998 }, { "userId": 5, "firstName": "jone", "lastName": "mac", "Gender":"Male", "year of birth":2001 } ] } JAVA const movieTable = document.getElementById("movieTable") fetch("user.json") .then(response => response.json()) .then(data => { console.log(data); data.map((movie => { usersTable.innerHTML+= ` ${users.userId} ${users.firstName} ${users.lastName} ${users.yearofbirth} ${users.gender} ` })) }); HTML USERS     userId firstName lastName year of birth gender

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Home work question. (html/java)

should be possible for someone to select the user by gender. You should be using the select element within the id selectgender to be able to do this .The select element should also be an option to select "All" genders.  This filter should combine appropriately with the year of birth filter as well. For example,if male is chosen then it should show all male users.

It should be possible for the someone to select a range of birth years, When they do this the table should update to show only the users for that range of years. For example if the years ranges are 2000 -2002 it should be only showing users in that year range.

I will include the java, json and html below . Any help will be great.

JSON

[

{

"users": [

{

"userId": 1,

"firstName": "Krish",

"lastName": "Lee",

"Gender":"Male",

"year of birth":2000

},

{

"userId": 2,

"firstName": "racks",

"lastName": "jacson",

"Gender":"Female",

"year of birth":1999

{

"userId": 3,

"firstName": "denial",

"lastName": "roast",

"Gender":"Male",

"year of birth":2002

},

{

"userId": 4,

"firstName": "devid",

"lastName": "neo",

"Gender":"Non binary",

"year of birth":1998

},

{

"userId": 5,

"firstName": "jone",

"lastName": "mac",

"Gender":"Male",

"year of birth":2001

}

]

}

JAVA

const movieTable = document.getElementById("movieTable")

fetch("user.json")

.then(response => response.json())

.then(data => {

console.log(data);

data.map((movie => {

usersTable.innerHTML+= `

<tbody><tr>

<td> ${users.userId}</td>

<td> ${users.firstName}</td>

<td> ${users.lastName}</td>

<td> ${users.yearofbirth}</td>

<td> ${users.gender}</td>

</tr>

</tbody></table>`

}))

});

HTML

<!DOCTYPE html>

<html lang="en"><head>

<meta http-equiv="content-type" content="text/html; charset=UTF-8">

<meta charset="utf-8">

<title>USERS</title>

<script defer src="user.js"></script>

</head>

 

<select id="selectbirth1">

<option value="1998">1998</option>

<option value="1999">1999</option>

<option value="2000">2000</option>

<option value="2001">2001</option>

<option value="2002">2002</option>

</select>

<select id="selectbirth2">

<option value="1998">1998</option>

<option value="1999">1999</option>

<option value="2000">2000</option>

<option value="2001">2001</option>

<option value="2002">2002</option>

<select id="selectgender">

<option value="Male">Male</option>

<option value="Female">Female</option>

<option value="Non binary">2000</option>

 

</select>

</select>

<table id="usersTable">

<tbody><tr>

<th>userId</th>

<th>firstName</th>

<th>lastName</th>

<th>year of birth </th>

<th>gender</th>

</tr>

</tbody></table>

 

</body></html>

Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Array
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
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education