Issue in encoding the query string

URI.encode_www_form is converting space to ‘+’.could someone suggest which method converts(encodes) space to ‘%20’


I would suggest you to try this way:

URI.encode_www_form(params).gsub("+", "%20")

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs