Rex once wrote a wonderful “escape” function that allowed you to escape characters for transferring scripts over SSH.
http://forum.mikrotik.com/t/function-of-transferring-the-script-over-ssh/163718/12
It supports ASCII 1252 encoding. Is it possible to ask the author to remake it so that it supports ASCII 1251 (Cyrilic) encoding?
And why don’t you ask directly on that topic, instead of opening another one?
ASCII is ASCII, has nothing to do with CP1252 or CP1251
I have a lot of text in Russian in my scripts (for example, in comments). Will your Escape function work with them? Or do you need to replace the conversion tables in it?
==>> ASCII is ASCII, has nothing to do with CP1252 or CP1251
Why don’t you try it yourself instead of asking?
Byte rapresentation is a byte rapresentation.
Dear Rex , That’s why I’m asking, because I don’t want to try “idle”. You, as an expert and an author, will tell me right away…
There are no codepages in “ASCII conversion”. The tables in referenced code just put a byte in to array of strings to workaround RouterOS does have not atoi() C-lib-like function.
If you have scripts with Cyrillic comments in it… it’s up the text editor/terminal you’re using to know the codepage for displaying the comments – e.g. the viewer has to know what codepage to use & nothing in script source is going to denote what codepage comments are in (e.g. “Byte representation is a byte representation”).
Using UTF-8 in the comments may be better approach, than using an assuming a specific codepage. Most editors/terminal assume UTF-8 not an extended ASCII codepage.