repl.it
HTML, CSS, JS

madlibss

fork
loading
Files
  • index.html
  • script.js
  • style.css
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<!DOCTYPE html>
<html>
 <head>
  <meta charset="utf-8" />
 </head>
 <body>
 
    <h1>Mad Libs</h1>
     
    <ul>
      <li>Noun: <input type="text" id="noun"></li>
      <li>Adjective: <input type="text" id="adjective"></li>
      <li>Second Noun: <input type="text" id="noun2"></li>
     <li>Second Adjective: <input type="text" id="adjective2"></li>
        <li>Verb: <input type="text" id="verb"></li>
    </ul>
     
    <button id="lib-button">Hit me. I dare you!</button>
      
    <p>Generated story: 
    <span id="story"></span>
    </p>
  <script src="script.js"></script>
 </body>
</html>
result
console