Survey Form - Build a Survey Form

Tell us what’s happening:
what the problem in my code about
“You should have a label element with an id of number-label .”

Your code so far

<!-- file: index.html -->
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8">
    <title>freeCodeCamp Survey Form</title>
    <link rel="stylesheet" href="styles.css">
  </head>
  <body>
    <h1 id="title">freeCodeCamp Survey Form</h1>
    <p id="description"><i>Thank you for taking the time to help us improve the platform</i></p>
    <form id="survey-form">
      <fieldset>
        <label id="name-label" for="name">Name <input id="name" type="text" placeholder="Enter your name" required /></label>
        <label id="email-label" for="email">Email <input id="email" type="email" placeholder="Enter your email" required /></label
        <label id="number-label" for="age">Age <input id="number" type="number" min="13" max="120" placeholder="Age" required/></label>
        <label id="describes">Which option best describes your current role?
          <select id="dropdown">
            <option value="">Select current role</option>
            <option value="1">Student</option>
            <option value="2">Full Time Job</option>
            <option value="3">Full Time Learner</option>
            <option value="4">Prefer not to say</option>
            <option value="5">Other</option>
          </select>
        </label>
      </fieldset>
      <fieldset>
        <label for="recommend">Would you recommended freeCodeCamo to a friend?</label>
        <label for="definitely"><input id="definitely" type="radio"  value="friend" name="friend" class="inline" /> Definitely</label>
        <label for="maybe"><input id="maybe" type="radio" value="friend" name="friend" class="inline" /> Maybe</label>
        <label for"notsure"><input id="notsure" type="radio" value="friend" name="friend" class"inline"> Notsure</label>
    </fieldset>
    <fieldset>
      <label for="favorite-feature">What is your favorite feature of freeCodeCamp?
        <select id="favorite-feature">
          <option value="">Select an option</option>
          <option value="1">Challenges</option>
          <option value="2">Projects</option>
          <option value="3">Community</opyion>
          <option value="4">Open Source</option>
        </select>
      </label>
    </fieldset>
    <fieldset>
      <label for="improved">What would you like to see improved? (check all that apply)</label>
      <label for="front-end"><input id="front-end" type="checkbox" value="apply" name="apply" class="inline" /> Front-end Projects </label>
      <label for="back-end"><input id="back-end" type="checkbox" value="apply" name="apply" /> Back-end Projects</label>
      <label for="data"><input id="data" type="checkbox" value="apply" name="apply" > Data Visualization </label>
      <label for="challenges"><input id="challenges" type="checkbox" value="apply" name="apply"> Challenges </label> 
      <label for="community"><input id="community" type="checkbox" value="apply" name="apply"> Open Source Community </label>
      <label for="help-rooms"><input id="help-rooms" type="checkbox" value="apply" name="apply"> Gitter help rooms </label>
      <label for="videos"><input id="videos" type="checkbox" value="apply" name="apply"> Videos </label>
      <label for="meetups"><input id="meetups" type="checkbox" value="apply" name="apply"> City Meetups </label>
      <label for="wiki"><input id="wiki" type="checkbox" value="apply" name="apply"> Wiki </label>
      <label for="forum"><input id="forum" type="checkbox" value="apply" name="apply"> Forum </label>
      <label for="course"><input id="course" type="checkbox" value="apply" name="apply"> Additional Course </label>
    </fieldset>
    <fieldset>
      <label for="comments-suggestions">Any Comments or suggestions<textarea id="comments-suggestions" name="comment-suggestions" rows="5" cols="50" placeholder="Enter your comment here"></textarea></label>
    </fieldset>
    <input id="submit" type="submit" value="Submit" />
  </form>
 </body>
</html>
      

          



/* file: styles.css */



Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36 Edg/110.0.1587.63

Challenge: Survey Form - Build a Survey Form

Link to the challenge:

You have made too many mistakes here:

  • <label for"notsure"> …missing = operator
  • </opyion>
  • class"inline"
  • </label
    .
    .
    .

The line in question should look like this:

<label id="number-label">Number
          <input type="number" id="number" min=5 max=25 placeholder="Num."></label>

Compare it to the same code line that you have created.

thanks mate already solved

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.