You're right to abstract this out into a method, but defining methods which aren't actions in controllers is a little unusual. If you're feeling fancy, I think the best approach would probably be to create a 'PPApi' module and move the logic into it:

`
module PPApi
  def self.search_result
    ....
`

Then calling methods from the module in the controller:

PPApi.search_result(lat, lng)

This way you keep your search logic encapsulated away from your controller.

Typically, we put our modules in lib/modules/, which means you also need to tweak your load paths to include them:
http://hemju.com/index.php/2010/09/rails-3-quicktip-autoload-lib-directory-including-all-subdirectories/

For example, we use this pattern here:
https://github.com/unepwcmc/magpie/tree/master/lib/modules