search function improved (checkbox implemented if to search or not to search)