escape query before submitting.
also make the search link on the homepage go to search
Merge pull request #325 from nla/hr-escape-search

Escape query before submitting.