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

              
                <form id="live-search" action="" class="styled" method="post">
    <fieldset>
        <h1>Live Search</h1>
        <input type="text" class="text-input" id="filter" placeholder="search" />
        <span id="filter-count"></span>
    </fieldset>
</form>

<nav>
    <ul class="liveSearchBar">
        <li><a href="#">Jim James</a></li>
        <li><a href="#">Hello Bye</a></li>
        <li><a href="#">Wassup Food</a></li>
        <li><a href="#">Contact Us</a></li>
        <li><a href="#">Bleep bloop</a></li>
        <li><a href="#">jQuery HTML</a></li>
        <li><a href="#">CSS HTML AJAX</a></li>
        <li><a href="#">HTML5 Net Set</a></li>
        <li><a href="#">Node Easy</a></li>
        <li><a href="#">Listing Bloop</a></li>
        <li><a href="#">Contact HTML5</a></li>
        <li><a href="#">CSS3 Ajax</a></li>
        <li><a href="#">ET</a></li>
    </ul>
</nav>
              
            
!

CSS

              
                .liveSearchBar, .liveSearchBar li{
  margin:0;
  padding:0;
  list-style:none;
}
.liveSearchBar, .liveSearchBar li a{
  color:#fff;
  text-decoration:none;
}
body{
  margin:0;
  background: #01B4FF;
  color:#fff;
  font-weight: 700;
  font-family: 'Brush Script MT', cursive;
  font-size: 20px;
}
#live-search fieldset{
  border:0;
  padding-left:0;
}
:focus{
  outline:none;
}
.text-input{
  height:30px;
  background: none;
  border:1px solid #fff;
  padding:5px ;
  font-family: 'Brush Script MT', cursive;
  font-size: 20px;
  color:#fff;
}
::-webkit-input-placeholder {
     color: #fff;
  }
  
  :-moz-placeholder { /* Firefox 18- */
     color: #fff;  
  }
  
  ::-moz-placeholder {  /* Firefox 19+ */
     color: #fff;  
  }
  
  :-ms-input-placeholder {  
     color: #fff;  
  }
              
            
!

JS

              
                $(document).ready(function(){
    $("#filter").keyup(function(){
 
        // Retrieve the input field text and reset the count to zero
        var filter = $(this).val(), count = 0;
 
        // Loop through the comment list
        $("nav ul li").each(function(){
 
            // If the list item does not contain the text phrase fade it out
            if ($(this).text().search(new RegExp(filter, "i")) < 0) {
                $(this).fadeOut();
 
            // Show the list item if the phrase matches and increase the count by 1
            } else {
                $(this).show();
                count++;
            }
        });
 
        // Update the count
        var numberItems = count;
        $("#filter-count").text("Number of Filter = "+count);
    });
});
              
            
!
999px

Console