Hello, I have a problem with Russian characters using http_get and parsing JSON with YAJL.
Can you please assist me with this? What should be set in order to see correct Russian characters when parsing JSON?
here's the code:
Job run's with 285 codepage. I've also tried 1025 ccsid for Russia but it didn't help.
I've checked JSON file and it is correct, so something must be changed in program. I don't have any clue for now.
Thanks in advance.
Can you please assist me with this? What should be set in order to see correct Russian characters when parsing JSON?
here's the code:
tempFile = http_tempfile() + '.xml';
HTTP_SetCCSIDs(1208:0);
HTTP_SetfileCCSID(1208);
//executing GET method
rc = http_get(%trim(w_Url):tempFile:w_Timeout);
if (rc <> 1 and rc <> 400);
unlink(tempFile);
w_errMsg = http_error();
return;
endif;
//then when I parse JSON I have unknown characters instead of Russian ones:
node = yajl_object_find( docNode : 'Name' );
Name = yajl_get_string(node);
Job run's with 285 codepage. I've also tried 1025 ccsid for Russia but it didn't help.
I've checked JSON file and it is correct, so something must be changed in program. I don't have any clue for now.
Thanks in advance.
Comment