search functionality for templates