How to use Chrome "Copy as cURL" for multipage / formal data post requests on Windows

I am developing a module for a web application. To run this module I need to send some data to the server. For simple forms, "Copy as cURL" from developer tools works fine (using curl from msys [git]), but for post requests with multipart / form-data, the copied string cannot be used in windows shell (cmd), and with bash (form msys); copied text is like

curl "http: //myserver.local" -H "Origin: http://wiki.selfhtml.org" -H "Accept-Encoding: gzip, deflate" -H "Accept-Language: de-DE, de; q = 0.8, en-US; q = 0.6, en; q = 0.4 "-H" User-Agent: Mozilla / 5.0 (Windows NT 6.1; WOW64) AppleWebKit / 537.36 (KHTML, like Gecko) Chrome / 43.0.2357.130 Safari / 537.36 "-H" Content-Type: multipart / form-data; boundary = ---- WebKitFormBoundaryntXdlWbYXAVwCIMU "-H" Accept: text / html, application / xhtml + xml, application / xml; q = 0.9, image / webp, * / *; q = 0.8 "-H" Cache-Control: max-age = 0 "-H" Referer: http://wiki.selfhtml.org/extensions/Selfhtml/frickl.php/Beispiel:HTML_form-Element1. html "-H" Connection: keep-alive "--data-binary" ------ WebKitFormBoundaryntXdlWbYXAVwCIMU "^
"Content-Disposition: form-data; name =" "area" "" ^

"multi" ^
"line" ^
"------ WebKitFormBoundaryntXdlWbYXAVwCIMU -" ^
"" --compressed

Is there a way I could use this or convert this to something useful?

+3


source to share





All Articles