I think I have done the needful please help https://codepen.io/Aondona/pen/ZEWZNjy

Tell us what’s happening:

Your code so far

Your browser information:

User Agent is: Mozilla/5.0 (Linux; Android 8.1.0; itel A16 Plus) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Mobile Safari/537.36.

Challenge: Build a Survey Form

Link to the challenge:

You’d also have to tell us which tests fail.

I suppose this one, for example:

User Story #5: Inside the form element, I am required to enter an email in a field with id="email".

Test that failed [the id of email and that of dropdown must be unique]
[Special characters must close]

So, the first test that fails is:

User Story #5: Inside the form element, I am required to enter an email in a field with id=“email”.

If you check your HTML, you might notice that you have no input field with an id of “email”. You’ve given that id to the label instead.

As for the second test, why do you have two dropdown menus, both with an id of “dropdown”?

As for the email I think it’s clear enough but for the drop-down do you advice that I remove one or if two I should change their id???
And another error message was that my special characters should be close where as I closed all and the error was emphasize on the name email age line. This how I close the < name=""</>etc so which close again

I’d suggest you remove one, because the challenge only asks you to create one dropdown. You can also try to change the id of the second dropdown and see if it passes.

It might be a good idea to run your HTML code through a validator, such as https://validator.w3.org. You will get error messages for the missing <!DOCTYPE>, <html>, <head> and <body> tags that aren’t required in codepen, you can ignore those, but you’ll also get a long list of other errors within the document, one of which addresses your issue (it’s not referring to the input with id=“name”, but you used a named character reference/special character (the copyright sign) which misses a closing semicolon in order to be valid).

1 Like

You are currently failing 4 of the tests.

For user story 4 & 11 you will need to use create an id called name just like in the email input.

For user story 9 you will need to add a min and max attribute to the age input. Like this

<input  min="10" max="99">

For user story 10 you will need to add the ids that FCC told you you do. The test suite error message will help with that.

1 Like

Your form looks good @ychris. Some things to revisit;

  • The test script should be included, with all tests passing, when you submit your projects.
    • Your page passes 15/17 user stories. Click the red button to see which test(s) are failing and text to help you correct the issue.
  • Run your HTML code through the W3C validator.
    • There are HTML coding errors you should be aware of and address.
    • Since copy/paste from codepen you can ignore the first warning and first two errors.
  • User’s should be able to click on the label to toggle a selection, not just the radio button / checkbox.
  • Change the cursor to a pointer when hovering over the submit button.
  • Do not use the <br> element to force line breaks or spacing. That’s what CSS is for.

Do you know you are “calling” font awesome icons but you have no link to to font awesome?

On this project I have done the needful what is my error . Am using the red button but can’t understand it further. I posted the link.

In the future please put the link in the body, not in the title. A link in the title is cannot be clicked.

What about the messages that you get don’t you understand?

The first message says;

If I enter an email that is not formatted correctly, I will see an HTML5 validation error.
Email field should be HTML5 validated : expected 'text' to equal 'email' 
AssertionError: Email field should be HTML5 validated : expected 'text' to equal 'email'

Your code has type of text and it should be email

The next failing message says;

For the name, email, and number input fields inside the form I can see corresponding labels that describe the purpose of each field with the following ids: id="name-label", id="email-label", and id="number-label".
#name-label is not defined : expected null to not equal null
AssertionError: #name-label is not defined : expected null to not equal null

You haven’t given the id's to the input fields.

Sorry don’t understand the message !!!

Hi @ychris.

Disregard the first message I found the link.

@Roma has given you very helpful answers to fixing the failing user stories. I would also revisit his suggestions about the br tag and font awesome icons.

1 Like