How to hide elements with specific attribute values with Jquery -


i have list this

<ul>  <li language="english"> australia </li> <li language="english"> america </li> <li language="french"> france </li> <li language="french"> canada </li> <li langauge="german"> germany </li>  </ul> 

i want filter , display list having language english. how can achieve using jquery?

and strategy if li has multiple attributes <li language="english,french"> canada </li>, want display canada both english french language speaking country.

appreciate if post exact code played hide() , not() while now.

something this:

<li language="english"> australia </li> <li language="english"> america </li> <li language="french"> france </li> <li language="french english"> canada </li> <li langauge="german"> germany </li>  $('li').not("[language*='english']").hide(); 

Comments

Popular posts from this blog

php - cannot display multiple markers in google maps v3 from traceroute result -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -