Learn HTML Forms by Building a Registration Form - Step 16

I can’t get this to pass. I don’t see any errors.

  **Your code so far**
/* file: index.html */
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Registration Form</title>
  <link rel="stylesheet" href="styles.css" />
</head>
<body>
  <h1>Registration Form</h1>
  <p>Please fill out this form with the required information</p>
  <form action='https://register-demo.freecodecamp.org'>
    <fieldset>
<label>Enter Your First Name: <input type="text" /></label>
     <label>Enter Your Last Name: <input type="text" /></label>
     <label>Enter Your Email: <input type="email" /></label>
     <label>Create a New Password: <input type="password" /></label>
    </fieldset>
    <fieldset></fieldset>
    <fieldset></fieldset>
  </form>
</body>
</html>
/* file: styles.css */
body {
width: 100%;
height: 100vh;
margin: 0;
background-color: #1b1b32;
color: #f5f6f7;
}

label {
display: block;
margin: 0.5rem 0;
}

  **Your browser information:**

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

Challenge: Learn HTML Forms by Building a Registration Form - Step 16

Link to the challenge:

I am not sure why you added types for inputs here. It is not required for this step, and it may be an issue.

// running tests You should add the first

input

after the

label

text

Enter Your First Name:

, and include a space after the colon.

Can’t get this to pass.

  **Your code so far**
/* file: index.html */
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Registration Form</title>
  <link rel="stylesheet" href="styles.css" />
</head>
<body>
  <h1>Registration Form</h1>
  <p>Please fill out this form with the required information</p>
  <form action='https://register-demo.freecodecamp.org'>
    <fieldset>
<label>Enter Your First Name: <input type="text" /></label>
<label>Enter Your Last Name: <input type="text" /></label>
<label>Enter Your Email: <input type="email" /></label>
<label>Create a New Password: <input type="password" /></label>
    </fieldset>
    <fieldset></fieldset>
    <fieldset></fieldset>
  </form>
</body>
</html>
/* file: styles.css */
body {
width: 100%;
height: 100vh;
margin: 0;
background-color: #1b1b32;
color: #f5f6f7;
}

label {
display: block;
margin: 0.5rem 0;
}

  **Your browser information:**

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

Challenge: Learn HTML Forms by Building a Registration Form - Step 16

Link to the challenge:

When I take type out it takes field box away.
this is error message:
You should add the first input after the label text Enter Your First Name:, and include a space after the colon.

1 Like

That’s strange. Try to remove type attributes from all inputs and post your code,
You can paste code like this:

My problem has not been solved.

Yeah, I know. In order to solve it, it would be helpful to see your code.
I was able to pass the tests with just removing type attributes from your code.
You said, however, that without type attributes you can not pass the tests.

So it would be helpful to see your version of code without type attributes.

That worked. Thank you!
So by putting in the input attributes, was I getting ahead of the lesson?

Yeah, probably.
Sometimes moves like that confuse the tests. I don’t know if it is always the case though

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