-1

Im using this Jquery Search FAQ : Jquery Search FAQ - Slight modification

But i need it to find the matching word without case sensitive, how can I do this?

Edit: this is the code im using:

$('#search').keyup(function(e) {
  var s = $(this).val().trim();
  if (s === '') {
    $('#result LI').show();
    return true;
  }
  $('#result LI:not(:contains(' + s + '))').hide();
  $('#result LI:contains(' + s + ')').show();
  return true;
});
<ul id="result" class="faq-ul"><br>
  <li><input type="checkbox" checked=""><i></i>
    <h2>Pregunta 1</h2>
    <p><br> Respuesta 1<br>
    </p>
  </li><br>
  <li><input type="checkbox" checked=""><i></i>
    <h2>Pregunta 2</h2>
    <p><br> Respuesta 2<br>
    </p>
  </li>
  <p></p>
</ul>
Gaspar
  • 63
  • 1
  • 7

1 Answers1

0

Duplicate, will delete once not accepted.

mbunch
  • 560
  • 7
  • 21