How to preserve '+' sign in params in rails 5
How to preserve '+' sign in params in rails 5 I have an uri like this /store?email=google+@gmail.com . Since '+' sign is allowed in email address, I need to preserve the plus sign. However, in rails 5, if I use params[:email] , I get google @gmail.com instead. How to prevent rails from converting '+' into space? I know we can first encode the url, and then decode it to preserve the '+' sign, but can I directly use params instead of extracting params from uri? Is there a way to preserve the plus sign in params ? /store?email=google+@gmail.com params[:email] google @gmail.com params params Also I tried using URI.decode_www_form_component params[:email] ,which still didn't work. And since the url is provided by external source I can't ask them to explicitly encode + as %2B . URI.decode_www_form_component params[:email] + %2B Any suggestions will be appreciated! How are you using that URI? Some things will URI escape,...
