Im trying to grab the users input value (:url) in my rails app. I believe its
params[:user_input]
but i dont know how to implement it into my controller. Do I place it anywhere or in a specific method?
Method
def index
@posts = Post.all
embedly_api = Embedly::API.new :key => '', :user_agent => 'Mozilla/5.0 (compatible; mytestapp/1.0; my@email.com)'
url = params[:user_input]
@obj = embedly_api.extract :url => :user_input
end
how can I get the user_input url so I can pass it into the hash???