undertaker Posted March 21, 2011 Share Posted March 21, 2011 I dont know if this is ajax, but i need some help with javascript using jquery. I. I have many images on page, and every one has some classes. Now i would like that when i insert that class into input field and press enter, all images with that class stays, and other dissapears. We could say it is some kind of search. For example: <img src="1.png" class="design boobs" /> <img src="2.png" class="design tractor" /> <img src="3.png" class="other obama" /> <img src="4.png" class="other ipad" /> so if i for example insert design and press enter, only 1 and 2 stays or if i insert boobs only 1 stays and other dissapear. EDIT: If there is possible i would also need an option to show all, and text if there werent any images found. Thanks -S Quote Link to comment https://forums.phpfreaks.com/topic/231266-filter-help/ Share on other sites More sharing options...
Adam Posted March 28, 2011 Share Posted March 28, 2011 Do you want to do this for a certain group of images, or for every image on the page? I can't imagine you'd want to hide any images used for the page's design or structure... Quote Link to comment https://forums.phpfreaks.com/topic/231266-filter-help/#findComment-1193187 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.