Survey Form - Build a Survey Form

Tell us what’s happening:
hello good day. I have two questions:
firstly, is it compulsory that we do the survey form project with the same content and format as the freeCodeCamp survey form?
secondly, I can seem to get my radio and checkbox buttons to be on the same line with the text, what should I do?

Your code so far

<!-- file: index.html -->
<!DOCTYPE html>
<html lang='en'>
    <meta charset='UTF-8'>
    <title>Basketball Survey Form</title>
    <link rel=stylesheet href='styles.css'>
    <h1 id='title'>Basketball Survey Exercise</h1>
    <p id='description'>Fill in the form below for a chance to be selected</p>
    <form id='survey-form'>
        <label id='name-label'>Full Name: <input type='text' id='name'placeholder='Enter your name' required /></label>
        <label id='email-label'>Email: <input type='email' id='email' placeholder='Enter your emial' required/></label>
        <label id='number-label'>Age: <input type='number' id='number' min='7' max='22' placeholder='age' required/></label>
 <label> Which option best describes your level of play: 
          <select id='dropdown'>
          <option>(select level)</option>
          <option>Adavnced Beginner</option>
    <label> Style of play: </label>    <label><input type='radio' name='play-style'class='style' /> Right hand </label>
        <label><input type='radio'name='play-style' class='style'/> Left hand </label>
        <label><input type='radio'name='play-style' class='style' /> Both </label>
  <label>Favourite positions to play? (select all that apply)</label>
  <input type='checkbox' value='position-of-play'/> Forward
  <input type='checkbox' value='position-of-play'/> Point Guard
  <input type='checkbox' value='position-of-play'/> Center
  <input type='checkbox' value='position-of-play'/> Small Forward
  <label> More info about you: <textarea placeholder='additional info'></textarea></label>
      <input type='submit' value='Submit'/>

/* file: styles.css */
body {
  width: 100%;
  height: 100vh;
  margin: 0;
  background-color: #1b1b32;
  color: #ffffff;
h1, p {
  margin: 1em auto;
  text-align: center;

form {
  max-width: 500px;
  min-width: 300px;
  width: 60vw;
  margin: 0 auto;

label {
  display: block;
  margin: 10px;
fieldset {
  border: 0;
  padding: 2rem auto;
input, textarea, select {
  width: 100%;
  margin-top: 10px;
  height: 25px;

textarea {
  width: 250px;
  height: 100px

input[type='submit'] {
  width: 100%;
  background-color:  #1b1b32;
  color: #ffffff;

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_5) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.1.1 Safari/605.1.15

Challenge: Survey Form - Build a Survey Form

Link to the challenge:

nope. you can make any type of form so long as you fulfill the given requirements.

ok thanks. any suggestions to the second question?

i think you should try to fix the html first as there are some issues there.
And use proper indenting and spacing so as to make it readable.
Beyond that, I would probably not nest my inputs inside the label, and instead I would lay them out side by side with a flex layout.

here’s an online html validator that can help you find syntax errors in html:

you can look up how to use flex layout here:

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