R
R
Rustam Salavatov2014-11-10 04:22:26
JSON
Rustam Salavatov, 2014-11-10 04:22:26

How to set Russian encoding in BATCH file with json CURL request?

Good afternoon
I'm doing a simple kind of script, but it came out crap with a Russian string.

SET /P TITLE=Enter NAME:

SET JSON="{\"name\":\"%TITLE%\"}"

curl.exe -H "Content-type: application/json" -X POST http://********.ru/video -d %JSON%

The text file itself, now in 866 encoding
, tried to drive it into different ones, to no avail ...
how to set it so that there are no problems when entering a Russian string?
maybe now it just either crashes or is not recorded,
as I understand it, you can bring it to the form
\u041c\u043e\u0439 \u0441\u0447\u0430\u0
but how to do it in batch
thanks

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question