Windows的wget-使用带引号的--post-data [英] wget for Windows - using --post-data with quotes

查看:334
本文介绍了Windows的wget-使用带引号的--post-data的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在Windows上使用wget,我想指定一个--post-data过滤器(并避免使用--post-file过滤器),但是我一直在努力使其工作.可能是因为在双引号中有这样的字符串:

I'm using wget for Windows and I want to specify a --post-data filter (and avoid using a --post-file filter) but I'm struggling to get it to work. It might be because there are strings within double quote marks like this :

wget "http://www.somesite.com/wfs" --header="Content-Type: text/xml; charset=UTF-8"
--user=username --password=password --no-check-certificate
--post-data="big long string with "quotes" in it" --output-document=C:\Test.xml

是否有其他人成功让--post-data在Windows的wget中工作?我想念什么吗?

Has anyone else successfully got --post-data to work in wget for Windows? Am I missing something?

欢呼

安迪

推荐答案

您可以在大的长字符串中加上引号\作为前缀,例如

You can escape the quotes in your big long string by prefixing them with \ e.g.

--post-data="big long string with \"quotes\" in it"

这篇关于Windows的wget-使用带引号的--post-data的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆