Class: Junebug::Controllers::Search
- Inherits:
-
Object
- Object
- Junebug::Controllers::Search
- Defined in:
- lib/junebug/controllers.rb
Instance Method Summary collapse
Instance Method Details
#post ⇒ Object
119 120 121 122 123 124 |
# File 'lib/junebug/controllers.rb', line 119 def post @search_term = input.q @page_title = "Search Results for: #{@search_term}" @pages = Page.find(:all, :conditions => ["body LIKE ? OR title LIKE ?", "%#{@search_term}%", "%#{@search_term}%" ]) render :search end |