From: Emanuele Torre Date: Fri, 12 Aug 2022 03:18:10 +0000 (+0200) Subject: docs/cmdline-opts: fix example and categories for --form-escape X-Git-Tag: curl-7_85_0~74 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2f0056680f9e7672e83599a0731156c8d7f9973f;p=thirdparty%2Fcurl.git docs/cmdline-opts: fix example and categories for --form-escape The example was missing a "--form" argument I also replaced "--form" with "-F" to shorten the line a bit since it was already very long. And I also moved --form-escape from the "post" category to the "upload" category (this is what I originally wanted to fix, before also noticing the mistake in the example). Closes #9298 --- diff --git a/docs/cmdline-opts/form-escape.d b/docs/cmdline-opts/form-escape.d index a3eecde6a2..a7fb189f8e 100644 --- a/docs/cmdline-opts/form-escape.d +++ b/docs/cmdline-opts/form-escape.d @@ -5,8 +5,8 @@ Help: Escape multipart form field/file names using backslash Protocols: HTTP See-also: form Added: 7.81.0 -Category: http post -Example: --form-escape --form 'field\\name=curl' 'file=@load"this' $URL +Category: http upload +Example: --form-escape -F 'field\\name=curl' -F 'file=@load"this' $URL --- Tells curl to pass on names of multipart form fields and files using backslash-escaping instead of percent-encoding. diff --git a/src/tool_listhelp.c b/src/tool_listhelp.c index 5b2df5645e..f3217be619 100644 --- a/src/tool_listhelp.c +++ b/src/tool_listhelp.c @@ -197,7 +197,7 @@ const struct helptxt helptext[] = { CURLHELP_HTTP | CURLHELP_UPLOAD}, {" --form-escape", "Escape multipart form field/file names using backslash", - CURLHELP_HTTP | CURLHELP_POST}, + CURLHELP_HTTP | CURLHELP_UPLOAD}, {" --form-string ", "Specify multipart MIME data", CURLHELP_HTTP | CURLHELP_UPLOAD},