Add custom method to transform a hash into query parameters. For Ruby 1.8.7 compatibility (it does not support URI::encode_www_form)