@MarkoLustro I have no idea what you are trying to do! so no. But you didn't answer if that web site is using a separate program to change hello to hel6o i assume it is. Is it in the server or in javascript in the page?
@MarkoLustro although I don't understand the problem, if you have a program that changes hello to hel6o then can you not just run that then typeset hel6o ?
@barbarabeeton it's just the same as tex, what could go wrong!
@MarkoLustro if you have a lua program that translates one string to another you can call that within luatex, here is an example that takes a string of cyrillic text in the document and uses a lua replacement program to convert that to a transliteration in latin script. As far as I understand your problem is the same, but with a more complicated transform
You can replace the pair И followed by an accent with the precomposed Í so long as you make sure that you search/replace for the longer string before the shorter one.
I just added two more gsub replacements to the file:
function cyrtr (s)
return
string.gsub(
string.gsub(
string.gsub(
string.g...