Rails 4 - Remote upload image

I have a bookmark controller.

My new.html.erb file has an input field called thumbnail url

So if someone fill that field with valid image url like http://example.com/image1.jpg, then I would like to remote upload that image to my server.

Can someone tell me whats the easiest way to do this?

Did you try paperclip …?? It seems to be pretty straightforward to configure and use.
You can then configure your server to do a get request on the resource and store it on your choice of storage

Agreed with Vineeth B S, although it could become a bit difficult to do and you might want to have a look at copyright issues.

But to accomplish, first install paperclip, https://github.com/thoughtbot/paperclip, then have a look at this post:

http://stackoverflow.com/questions/4851325/rails-3-paperclip-and-uploading-image-from-remote-url

good luck

Thankyou guys. I’m using paperclip now and it works fine.