Wikipedia is your friend for the various methods and how they are done.
Apart from utilizing JavaScript you can do something by looping over the characters and changing them to something else.
The simplist would be something like replace
0 with v
1 with 7
2 with ;
...
And so on.
Decoding would be the reverse.
It’s as tedius as it sounds. Athough there are shortcuts.
Anyways I’m going to have to defer to someone else to finish answering this one.