kyp*_*hos 39 quotes command escaping prompt curly-braces
我试图在命令提示符中执行以下行:
curl -X POST -d '{ "method" : "account_info", "params" : [ { "account" : "rHb9CJAWyB4rj91VRWn96DkukG4bwdtyTh"} ] }' http://s1.ripple.com:51234
Run Code Online (Sandbox Code Playgroud)
但是,我得到以下内容:
curl: (6) Could not resolve host: method
curl: (7) Failed connect to :80; No error
curl: (6) Could not resolve host: account_info,
curl: (6) Could not resolve host: params
curl: (7) Failed connect to :80; No error
curl: (3) [globbing] illegal character in range specification at pos 2
curl: (3) [globbing] unmatched brace at pos 2
curl: (6) Could not resolve host: account
curl: (7) Failed connect to :80; No error
curl: (3) [globbing] unmatched close brace/bracket at pos 35
curl: (3) [globbing] unmatched close brace/bracket at pos 1
curl: (3) [globbing] unmatched close brace/bracket at pos 1
unable to parse request
Run Code Online (Sandbox Code Playgroud)
我在Windows上,错误与引号,大括号和globbing有关.我尝试使用反斜杠来避免引号,没有运气.
我确信我只需要以正确的方式逃避正确的事情,但我很难做到这一点.一些帮助将受到高度赞赏.
Man*_*ich 57
试试这个:
curl -X POST -d "{ \"method\" : \"account_info\", \"params\" : [ { \"account\" : \"rHb9CJAWyB4rj91VRWn96DkukG4bwdtyTh\"} ] }" http://s1.ripple.com:51234
Run Code Online (Sandbox Code Playgroud)
can*_*ndu 36
你可以curl -g用来关闭globbing:
curl -g -X POST -d '{ "method" : "account_info", "params" : [ { "account" : "rHb9CJAWyB4rj91VRWn96DkukG4bwdtyTh"} ] }' http://s1.ripple.com:51234
Run Code Online (Sandbox Code Playgroud)
比逃避所有这些括号更容易.
| 归档时间: |
|
| 查看次数: |
37503 次 |
| 最近记录: |