Fixed the search text removing upon click. In addition, added basic paging code, but still a tad buggy when doing unusual combinations.