Refactored Search Controller and View

* Removed potential SQL injection vulnerability
* simplified code to follow media-list example set by browsing.