rubyメモ
require 'uri'
url = 'http://hogehoge.com/hogahoga.cgi?test=日本語テスト'
url_escape = URI.escape(url)
puts url_escape
#=> http://hogehoge.com/hogahoga.cgi?test=%e6%97%a5%e6%9c%ac%e8%aa%9e%e3%83%86%e3%82%b9%e3%83%88
puts URI.unescape(url_escape)
#=>http://hogehoge.com/hogahoga.cgi?test=日本語テスト