Survey page errors

Hi

My survey page had 10 errors that I’ve been battling with. I feel I have most of them right though.

User story #11,4,5,6,7,8,9,13,14,16

For example #10 says that I need to have a placeholder text and I do but it’s still showing as not complete

Please assist me with my errors because for some reason I cannot see the problem.

<link rel="stylesheet" href="style.css">

<title>
  Non-Olypmic Sports Survey Form
</title>


  <h1 id="title"> Non-Olympic Sports Survey Form </h1>



  <p id="description"> This survey is about non olympic sports and whether you think they should be in the olympics or not.</p>
  

<div id="name">
  <label id="name-label"> Your name </label>
  <input type="text" placeholder="enter name here" required>
</div>

<div id="email">
  <label id="email-label"> Your email </label>
  <input type="email" placeholder="enter email here" required>
</div>
<div id="number">
  <label id="number-label"> Cellphone </label>
  <input type="number" placeholder="number here" maxlength="10" max="10" required>
</div>
Do you like Pool?
<ul>
  <label for="No">
    <input id="No" type="checkbox" name="no-not really-sort of-yes"> No
  </label>
  <label for="Not really">
    <input id="Not really" type="checkbox" name="no-not really-sort of-yes"> Not really
  </label>
  <label for="Sort of">
    <input id="Sort of" type="checkbox" name="no-not really-sort of-yes"> Sort of
  </label>
  <label for="Yes">
    <input id="Yes" type="checkbox" name="no-not really-sort of-yes"> Yes
  </label>

</ul>

Do you think Pool should be in the Olympics?
<ul>
  <label for="No">
    <input id="No2" type="radio" name="no-not really-sort of-yes"> No
  </label>
  <label for="Not really">
    <input id="Not really4" type="radio" name="no-not really-sort of-yes"> Not really
  </label>
  <label for="Sort of">
    <input id="Sort of2" type="radio" name="no-not really-sort of-yes"> Sort of
  </label>
  <label for="Yes">
    <input id="Yes2" type="radio" name="no-not really-sort of-yes"> Yes
  </label>

</ul>

Do you like Darts?
<ul>
  <label for="No">
    <input id="No3" type="checkbox" name="no-not really-sort of-yes"> No
  </label>
  <label for="Not really">
    <input id="Not really3" type="checkbox" name="no-not really-sort of-yes"> Not really
  </label>
  <label for="Sort of">
    <input id="Sort of3" type="checkbox" name="no-not really-sort of-yes"> Sort of
  </label>
  <label for="Yes">
    <input id="Yes3" type="checkbox" name="no-not really-sort of-yes"> Yes
  </label>

</ul>

Do you think Darts should be in the Olympics?
<ul>
  <label for="No">
    <input id="No1" type="radio" name="no-not really-sort of-yes"> No
  </label>
  <label for="Not really">
    <input id="Not really1" value="Not really" type="radio" name="no-not really-sort of-yes"> Not really
  </label>
  <label for="Sort of">
    <input id="Sort of1" type="radio" name="no-not really-sort of-yes"> Sort of
  </label>
  <label for="Yes">
    <input id="Yes1" type="radio" name="no-not really-sort of-yes"> Yes
  </label>

</ul>

<div class="input-field">
  Please let us know what you think or if any other sport should be in the Olympics?
	<textarea placeholder="Your comments"> </textarea> 
</div>

<button id="submit" type="button"> Submit</button>

Hello~!

Do you have a link to a live version of this project?

https://codepen.io/kyle-akaloo/pen/QWyxoPj

Hey Vegeta.

Seems like you’ve missed to put an id attribute on your input elements.

As an example, your number input element should have the attribute id=“number”

I have that here though…

 <div id="number">
  <label id="number-label"> Cellphone </label>
  <input type="number" ***id="number"*** placeholder="number here" maxlength="10"  max="10" required>
</div>
1 Like

True, seems i was a bit hasty.

Your input fields are however enclosed within divs like

<div id="number">
</div>

Removing these for each input element makes the tests pass.

1 Like

id must be unique - you have some ids used multiple times in your page. Try fixing that

2 Likes

No problem, appreciate the help. It’s sorted.

Thanks. Now I just need to sort out my drop down.

I’m having problems with userstory 12 (dropdown) … I have the dropdown and it seems to be working but I don’t know why it’s not selecting an option or why it’s not passing?

Please have a look at my dropdown and see if you can find the problem.

you are not using the correct tag: https://www.w3schools.com/tags/tag_select.asp

2 Likes