Re: [nodejs] "querystring" works incorrectly?

42 views
Skip to first unread message

Ben Noordhuis

unread,
Oct 15, 2012, 7:28:17 AM10/15/12
to nod...@googlegroups.com
On Mon, Oct 15, 2012 at 10:39 AM, Aivis Siliņš <aivis....@gmail.com> wrote:
>> var querystring = require('querystring');
>> querystring.stringify({ foo: '!'});
>
> Actual output:
> 'foo=!'
>
> Expected output:
> 'foo=%21'
>
> Why node.js query string don't encode some chars?

Because it's in the RFC. You can find the details in section 2.2 of RFC 1738.
Reply all
Reply to author
Forward
0 new messages