I have the below html code, also i will have a textbox for entering the keyword, What i want is while the user writing in this textbox the javascript search in this html code using the FirstName and LastName , and while comparing items, if an item didn't match i want to display:none its container div. How can i do that using JS and work on firfox and IE
<div id="contact_4" >
<input class="contactChk" id="chk_4" type="checkbox" />
<img alt="" src='img/4.jpg' width="25px" height="25px" />
<span id="contactName_4" class="contactItem">
FirstName LastName
</span>
<br />
</div>
<div id="contact_5" >
<input class="contactChk" id="chk_5" type="checkbox" />
<img alt="" src='img/5.jpg' width="25px" height="25px" />
<span id="contactName_5" class="contactItem">
ACharName AnyLast
</span>
<br />
</div>
<div id="contact_6" >
<input class="contactChk" id="chk_6" type="checkbox" />
<img alt="" src='img/6.jpg' width="25px" height="25px" />
<span id="contactName_6" class="contactItem">
BCharName AnyLast
</span>
<br />
</div>
<div id="contact_7" >
<input class="contactChk" id="chk_7" type="checkbox" />
<img alt="" src='img/7.jpg' width="25px" height="25px" />
<span id="contactName_7" class="contactItem">
CCharName AnyLast
</span>
<br />
</div>