Survey Form - Build a Survey Form

I just need to know how to make a desendent

Your code so far

<!-- file: index.html -->
<DOCTYPE! html> <html lang="en">
<head> <meta charset="UTF-8">
<title> Survey form</title>
<link rel="stylesheet" href="styles.css"> </head> <body> <div class="container"> <header class="header">
  <h1 id="title">Survey form</h1>
  <p id="description">Please fill these out</p></header>
 <form id="survey-form"></form> 
 <div class="form group"><label id="name-label" for="name">Name</label>
  <input type="text" id="name" name="name" placeholder="Put in your name"required></div></input>
  <idv class="form group"></label
  id="email-label" for="email">Email</label>
  <input id=email type="email"placeholder="Put in your email" required></input>

  
  


</body>
/* file: styles.css */

Your browser information:

User Agent is: Mozilla/5.0 (X11; CrOS x86_64 14541.0.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36

Challenge Information:

Survey Form - Build a Survey Form

Not sure what you mean by this.

If it is the test message telling you some form element (like an input) should be a descendant of the form it means it should be inside the form element.

<form id="survey-form"></form> 

You closed the form. All the form elements should be inside this element.

Your html declaration is not correct.

Your head element is didn’t have closing tag.

Your all element should goes between body opening and closing tags.

Your form opening and closing tags should be around your form content.
@ayatali

You are correct on the first and last points, but there is a closing head tag,

And the elements are in the body

<body> <div class="container"> <header class="header">
  <h1 id="title">Survey form</h1>
  <p id="description">Please fill these out</p></header>
 <form id="survey-form"></form> 
 <div class="form group"><label id="name-label" for="name">Name</label>
  <input type="text" id="name" name="name" placeholder="Put in your name"required></div></input>
  <idv class="form group"></label
  id="email-label" for="email">Email</label>
  <input id=email type="email"placeholder="Put in your email" required></input>

  
  


</body>

The other two points were good notes for the OP to fix

2 Likes

Oh! Thank you for correction.

2 Likes

Thanks! that was really helpful!

Thanks! that was really helpful