This is an example of how to use Searchgasm in a rails app. Searchgasm is simple searching, ordering, and pagination all in one plugin.
Checkout Searchgasm here: github.com/binarylogic/searchgasm Quick tutoiral on how to build this application here: www.binarylogic.com/2008/9/7/tutorial-pagination-ordering-and-searching-with-searchgasm
Here are the files you want to glance at:
1. app/controllers/users_controller.rb 2. app/views/users 3. app/controllers/orders_controller.rb (same as users, but AJAX) 4. app/views/orders 5. config/initializers/searchgasm.rb