Class: RequestsController

Inherits:
ActionController::Base
  • Object
show all
Defined in:
app/controllers/requests_controller.rb

Instance Method Summary collapse

Instance Method Details

#fetchObject



6
7
8
9
10
# File 'app/controllers/requests_controller.rb', line 6

def fetch
  url = params['url'] || ''
  uri = URI(url)
  render :text => Net::HTTP.get(uri)
end