From: "Nicholas A." Date: 2011-02-24T03:11:44+09:00 Subject: Re: How to automate download pdf from web in ruby You can do it with CGI: #!/usr/bin/ruby puts "Content-Type: application/x-unknown\n\n" puts "Content-Length: application/x-unknown\n\n" puts "Content-Disposition: attachment; filename=abc.pdf\n\n" # output the binary file data here... -- Posted via http://www.ruby-forum.com/.