From: Michael Peterson Date: 2011-03-02T14:44:04+09:00 Subject: Re: How to automate download pdf from web in ruby > > I want to download pdf file from website. But i cannot use rails > "send_file" as i want it in ruby only. > > e.g : http://www.example.com/abc.pdf > > Now from above URL I just want to automate download "abc.pdf" rather > than > The simplest pure-ruby way to do it that I know of is to use the rio library: I just ran this simple program and it downloaded the pdf perfectly: require 'rubygems' require 'rio' rio("http://www.sqlite.org/copyright-release.pdf") > rio('sqlite-copyright-release.pdf') -Michael -- Posted via http://www.ruby-forum.com/.