Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs 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 its URL and the proper URL extension.

+ add another resource


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


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.


Auto Save

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.


                <div id="rock">
<div id="frame">
<h1 id="title">Music Habits Survey</h1>
<p id="description">Let us know what you think</p>
<form id="survey-form" action="#">
  <label for="name" id="name-label">Name</label>
   <input type="text" id="name" placeholder="Type your name" required><br><br>
  <label for="email" id="email-label">Email</label>
   <input type="email" id="email"  placeholder="Type your email" required><br><br>
  <label for="number" id="number-label">Concerts you attended in the last three months</label>
   <input type="number" id="number" min="1" max="5"  placeholder="Type a number"><br><br>
   <label>Favourite music streaming service</label>
  <select id = "dropdown">
    <option value = "1">Spotify</option>
    <option value = "2">Apple Music</option>
    <option value = "3">Play Music</option>
    <option value = "4">Amazon Unlimited</option>
  <label for="music" id="music-label">What is your favorite music genre?</label>
  <input type="radio" name="music" value="rock" checked>Rock 
  <input type="radio" name="music" value="pop">Pop 
  <input type="radio" name="music" value="jazz">Jazz <br><br>
  <label for="time-music" id="checkbox-label">How long do you listen to music every week?</label><br>
    <input type="checkbox" name="time-music" value="1" checked> Less than 1 hour<br>
  <input type="checkbox" name="time-music" value="1-1"> Between 1 and 2 hours<br>
  <input type="checkbox" name="time-music" value="2"> More than 2 hours<br><br>
   <label for="comments" id="comments-label">Any further comments about your music comsumption habits?</label><br><br>
  <textarea name="comments" form="usrform">Enter text here...</textarea><br><br>
    <input type="submit" id="submit" value="Submit">


                html, body {
  margin-top: -15px;
  margin-right: -15px;
  margin-left: -15px;
  padding: 0px;
    font-family:"Trebuchet MS", Helvetica, sans-serif;
    color: white;
#rock {
  background-image: url("");
   background-size: auto auto;
  background-position: center;
   background-repeat: no-repeat;
  height: 900px;
#frame {
  background-color: grey;
  padding: 30px;
  height: 850px;
  opacity: 0.96;
#number {
  width: 105px;
#title {
  margin-top: 100px;
#description {
  margin-top: -10px;
  margin-bottom: 40px;
  font-size: 1.3em;


                // coded by @SamAI-Software
const projectName = 'survey-form';
localStorage.setItem('example_project', 'Survey Form');