implemented search result pagination