title: Search for a word using jquery
body: <p>There are lot of features for a product x, i want to make a search field so that users can easily find a particular feature of x easily.
  so here's what i have come up with (i stumbled upon this code from a bootstrap webpage).</p>
  
  <pre><code>&lt;div class="container"&gt;
      &lt;div class="row"&gt;
          &lt;h2 class="text-primary title"&gt;&lt;span class="glyphicon glyphicon-align-justify"&gt;&lt;/span&gt;User list&lt;/h2&gt;
          &lt;div class="col-lg-12"&gt;
              &lt;input type="search" class="form-control" id="input-search" placeholder="Search..." &gt;
          &lt;/div&gt;
          &lt;div class="searchable-container"&gt;
              &lt;div class="items col-xs-12 col-sm-6 col-md-6 col-lg-6 clearfix"&gt;
                 &lt;div class="info-block block-info clearfix"&gt;
                      &lt;div class="square-box pull-left"&gt;
                          &lt;span class="fa fa-user"&gt;&lt;/span&gt;
                      &lt;/div&gt;
                      &lt;h5 class="text-success"&gt;Company Name&lt;/h5&gt;
                      &lt;h4&gt;sms&lt;/h4&gt;
                      &lt;p&gt;Title: Manager&lt;/p&gt;
                      &lt;span&gt;Email: sample@company.com&lt;/span&gt;
                  &lt;/div&gt;
              &lt;/div&gt; 
  
          &lt;/div&gt;
      &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>script code</p>
  
  <pre><code>&lt;script&gt;
  
  jQuery(document).ready(function($){   
          $('#input-search').on('keyup', function() {
            var rex = new RegExp($(this).val(), 'i');
              $('.searchable-container .items').hide();
              $('.searchable-container .items').filter(function() {
                  return rex.test($(this).text());
              }).show();
          });
      });
  &lt;/script&gt;
  </code></pre>
  
  <p>the problem is that this script searches for a particular word inside whole paragraph. i want only the heading to be searched. ie,<code>&lt;h5 class="text-success"&gt;Company Name&lt;/h5&gt;</code> not the whole thing. how can i do that? i tried something like this but with no success</p>
  
  <pre><code> jQuery(document).ready(function($){   
              $('#input-search').on('keyup', function() {
                var rex = new RegExp($(this).val(), 'i');
                  $('.searchable-container .text').hide();
                  $('.searchable-container .text').filter(function() {
                      return rex.test($(this).text());
                  }).show();
              });
          });
  </code></pre>