curl - How to escape single quotes into double quotes into single quotes -
here example of command line fit description :
curl http://dumbdomain.com/solr/collection2/update/json -h 'content-type:application/json' -d ' { "add": { "doc": { "uid": "79729", "text" : "i''ve got number"} } }'
i tried \' (not escaped), url encoded (not urldecoded @ other end!) , '' (quote disappear!), without success.
if replace ' unicode encoded ' (which \u0027), works:
curl http://dumbdomain.com/solr/collection2/update/json -h 'content-type:application/json' -d ' { "add": { "doc": { "uid": "79729", "text" : "i\u0027ve got number"} } }'
strange, worth know!
Comments
Post a Comment