Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <h1 id="title">Metro University Survey Form</h1>

  <p id="description">Thank you for taking the time to help us improve </p>

<form id="survey-form">
  
  <div id="body">
    
  <div>
  <label for="name" id="name-label">
    <p>Name:</p>
    </label>
    
  <input name="name" id="name"  type="text" placeholder="Enter your name" required>
  </div>
  
  <div>
    <label for="email" id="email-label">
      <p>Email:</p>
      </label>
    <input name="email" id="email"  type="email"  placeholder="Enter your email" required>
  </div>
  
  <div>
    <label for="number" id="number-label">
      <p>Age(optional)</p>  
      </label>
    <input name="name" id="number" id="number-label" type="number" placeholder="Age" required min=10 max=99>
  </div>
  
  <div>
    <label for="mylist">
      <p>Which option best describes your current role?</p></label>
    
    <select name="role" id="mylist">
      <option value="">select current role</option>
      <option value="student">Student</option>
      <option value="lecturer">Lecturer</option>
      <option value="parent">Parent</option>
      <option value="aspirant">Aspirant</option>
      <option value="Other">Other</option>
              </select>
  </div>
  
  <div>
  <p>Would you recommend Metro to a friend?</p>
  <label for="radio1">
    <input id="radio1" type="radio" name="definitely-maybe-not sure" value="radio1">  Definitely
    </label>
    
   <label for="radio2">
    <input id="radio2" type="radio" name="definitely-maybe-not sure" value="radio2">  Maybe
    </label>
    
   <label for="radio3">
    <input id="radio3" type="radio" name="definitely-maybe-not sure" value="radio3">  Not Sure 
    </label>
    
  </div>
  <div>
    <label for="dropdown"><p>What do you like about Metro?</p></label>
  
  <select name="features" id="dropdown">
    <option value="">Select an option</option>
    <option value="environment">Environment</option>
    <option value="infrastructure">Infrastructure</option>
    <option value="community">Community</option>
    <option value="lecture">lectures</option>
    </select>
    </p></div>
  
  <p> What would you like to see improved? (Check all that apply)</p>
  
    <div>
    <input type="checkbox" id="classrooms" name="improvement" value="classroom">
    <label for="classrooms"> Classrooms</label>
  </div>
    
    <div>
    <input type="checkbox" id="transport" name="improvement" value="transport">
    <label for="transport"> Transport</label>
    </div>
  
  <div>  
    <input type="checkbox" id="hostel" name="improvement" value="hostel">
    <label for="hostel"> Hostel</label>
    </div>
  
   <div>
    <input type="checkbox" id="electricity" name="improvement" value="electricity">
    <label for="electricity"> Electricity</label>
  </div>
  
   <div>
    <input type="checkbox" id="library" name="improvement" value="library">
    <label for="library"> Library</label>
  </div>
  
     <div>
    <input type="checkbox" id="website" name="improvement" value="website">
    <label for="website"> Website</label>
  </div>
  
  <div>
    <label for="comment"><p>Any comments or suggestions?</p></label>
    
    <textarea id="comment" name="comment"
          rows="5" cols="33" placeholder="Enter your comments here"></textarea>
  </div>
    <br>
  <button id="submit">Submit</button>
</form>
  
  </div>
              
            
!

CSS

              
                body {
  font-family: sans-serif;
  text-align: center;
  background-image: linear-gradient(to bottom right, #33adff, green);
  color: white;
}

#title {
  font-size: 45px;
}

#description {
  font-size: 20px;
}

#body {
  width: 600px;
  padding: 30px;
  margin: auto;
  background-color: rgba(0, 0, 0, 0.6);
  border-radius: 10px;
  text-align: left;
  font-size: 20px;
  color: white;
}

#name {
  width: 560px;
  padding: 15px;
  border-radius: 10px;
}

#email {
  width: 560px;
  padding: 15px;
  border-radius: 10px;
}

#number  {
  width: 560px;
  padding: 15px;
  border-radius: 10px;
}

#mylist {
  width: 600px;
  padding: 15px;
  border-radius: 10px;
}

#dropdown  {
  width: 560px;
  padding: 10px;
  border-radius: 10px;
}

#comment {
  width: 560px;
  padding: 10px;
  border-radius: 10px;
  border: none;
}

#submit  {
  width: 560px;
  padding: 15px;
  border-radius: 10px;
  font-size: 20px;
  border: none;
  color: white;
  background-color: green;
}
              
            
!

JS

              
                
              
            
!
999px

Console