updated search and category functionality