cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: [PATH] --data-urlencode

From: <jon_at_linertia.com>
Date: Mon, 19 Nov 2007 18:38:50 -0800 (PST)

> Hi
>
> Attached to this mail is a patch that introduces the --data-urlencode
> option,
> as previously discussed. I do have some further thoughts about it that I'd
> welcome feedback on! Here's the current usage:
>
> --data-urlencode name=content
>
> and
>
> --data-urlencode name_at_filename
>
> The 'name' part is not encoded, only the content part (which can be loaded
> from a file). Will we need any further tweaks, like allowing the entire
> given
> string to be encoded in case someone wants to post something that isn't in
> "name=var" style?
>
> Currently, the name part just cannot contain a '=' or '@' letter as they
> will
> be treated as separators between the name and the following data. Should
> we
> allow a way to quote them or just live with that limitation?
>
> This whole urlencode thing is introduced only to make it easier to write
> scripts etc that do posts, as it removes the need for the scripts to do
> the
> somewhat complicated procedure of url-encoding the data. Even though very
> few
> people commented on this thread previosuly, I do believe this option will
> be
> appreciated by the crowds once we provide it...
>
> So, what are your comments and suggestions?
>
> --
> Commercial curl and libcurl Technical Support: http://haxx.se/curl.html

I think it's an excellent idea. For me, at least, I go to some website
that converts it for me, but this would do the job.
Received on 2007-11-20