unicode.html 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
  2. <html>
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <link type="text/css" rel="stylesheet" href="css/style.css" />
  7. <link type="text/css" rel="stylesheet" href="css/color_day.css" id="colorchange" />
  8. <link type="text/css" rel="stylesheet" href="css/style_mobile.css" media="screen and (max-width:767px)">
  9. <link type="text/css" rel="stylesheet" href="css/alertify.css" id="alertifyCSS">
  10. <title>Maha Paritta</title>
  11. <script language="javascript" src="js/common.js"></script>
  12. <script language="javascript" src="js/xml.js"></script>
  13. <script language="javascript" src="js/filenew.js"></script>
  14. <script language="javascript" src="charcode/sinhala.js"></script>
  15. <script language="javascript">
  16. function sangayana2unicode(inStr, inM, inM2) {
  17. var output = inStr;
  18. output = output.replace(/ñ/g, "ṭ");
  19. output = output.replace(/à/g, "ā");
  20. output = output.replace(/ã/g, "ī");
  21. output = output.replace(/å/g, "ū");
  22. output = output.replace(/ï/g, "ṅ");
  23. output = output.replace(/¤/g, "ñ");
  24. output = output.replace(/ó/g, "ḍ");
  25. output = output.replace(/õ/g, "ṇ");
  26. output = output.replace(/ë/g, "ḷ");
  27. output = output.replace(/ü/g, inM);
  28. output = output.replace(/§/g, inM);
  29. output = output.replace(/â/g, "Ā");
  30. output = output.replace(/ä/g, "Ī");
  31. output = output.replace(/æ/g, "Ū");
  32. output = output.replace(/ð/g, "Ṅ");
  33. output = output.replace(/¥/g, "Ñ");
  34. output = output.replace(/ò/g, "Ṭ");
  35. output = output.replace(/ô/g, "Ḍ");
  36. output = output.replace(/ö/g, "Ṇ");
  37. output = output.replace(/ì/g, "Ḷ");
  38. output = output.replace(/ý/g, inM2);
  39. return (output);
  40. }
  41. function s2u() {
  42. mstr = document.getElementById("m_str").value;
  43. mlower = mstr.split(",")[0];
  44. mupper = mstr.split(",")[1];
  45. txt = document.getElementById("txtInput").value;
  46. document.getElementById("txtOutput").value = sangayana2unicode(txt, mlower, mupper);
  47. }
  48. function sinhala_old() {
  49. txt = document.getElementById("txtInput").value;
  50. output = "";
  51. for (i = 0; i < char_si_a.length; i++) {
  52. var src = char_si_a[i].id;
  53. var dest = char_si_a[i].value;
  54. var strReplace = "txt = txt.replace(/" + src + "/g, dest);";
  55. eval("txt = txt.replace(/" + src + "/g, dest);");
  56. }
  57. txt = txt.replace(/ර/g, "ra");
  58. txt = txt.replace(/ය/g, "ya");
  59. document.getElementById("txtOutput").value = txt;
  60. }
  61. function sinhala() {
  62. var txt = document.getElementById("txtInput").value;
  63. output = "";
  64. try {
  65. //replace begin
  66. txt = txt.replace(/ක‍්ක්‍ර/g, "kkra");
  67. txt = txt.replace(/ක‍්ක්‍ය/g, "kkya");
  68. txt = txt.replace(/ක‍්ඛ්‍ර/g, "kkhra");
  69. txt = txt.replace(/ක‍්ඛ්‍ය/g, "kkhya");
  70. txt = txt.replace(/ක්‍ව්‍ර/g, "kvra");
  71. txt = txt.replace(/ක්‍ව්‍ය/g, "kvya");
  72. txt = txt.replace(/ඛ්‍ය්‍ර/g, "khyra");
  73. txt = txt.replace(/ඛ්‍ය්‍ය/g, "khyya");
  74. txt = txt.replace(/ඛ‍්ව්‍ර/g, "khvra");
  75. txt = txt.replace(/ඛ‍්ව්‍ය/g, "khvya");
  76. txt = txt.replace(/ග‍්ග්‍ර/g, "ggra");
  77. txt = txt.replace(/ග‍්ග්‍ය/g, "ggya");
  78. txt = txt.replace(/ග‍්ඝ්‍ර/g, "gghra");
  79. txt = txt.replace(/ග‍්ඝ්‍ය/g, "gghya");
  80. txt = txt.replace(/ක්ක්‍ර/g, "kkuṃ");
  81. txt = txt.replace(/ක්ක්‍ය/g, "kkra");
  82. txt = txt.replace(/ක‍්කිං/g, "kkiṃ");
  83. txt = txt.replace(/ක‍්කුං/g, "kkuṃ");
  84. txt = txt.replace(/ක්ඛ්‍ර/g, "kkhra");
  85. txt = txt.replace(/ක්ඛ්‍ය/g, "kkhya");
  86. txt = txt.replace(/ක‍්ඛිං/g, "kkhiṃ");
  87. txt = txt.replace(/ක‍්ඛුං/g, "kkhuṃ");
  88. txt = txt.replace(/ක්‍යිං/g, "kyiṃ");
  89. txt = txt.replace(/ක්‍යුං/g, "kyuṃ");
  90. txt = txt.replace(/ක්‍යිං/g, "kyiṃ");
  91. txt = txt.replace(/ක්‍යුං/g, "kyuṃ");
  92. txt = txt.replace(/ක්‍රිං/g, "kriṃ");
  93. txt = txt.replace(/ක්‍රුං/g, "kruṃ");
  94. txt = txt.replace(/ක්‍රිං/g, "kriṃ");
  95. txt = txt.replace(/ක්‍රුං/g, "kruṃ");
  96. txt = txt.replace(/ක්ව්‍ර/g, "kvra");
  97. txt = txt.replace(/ක්ව්‍ය/g, "kvya");
  98. txt = txt.replace(/ක්‍විං/g, "kviṃ");
  99. txt = txt.replace(/ක්‍වුං/g, "kvuṃ");
  100. txt = txt.replace(/ඛ්‍යිං/g, "khyiṃ");
  101. txt = txt.replace(/ඛ්‍යුං/g, "khyuṃ");
  102. txt = txt.replace(/ඛ‍්විං/g, "khviṃ");
  103. txt = txt.replace(/ඛ‍්වුං/g, "khvuṃ");
  104. txt = txt.replace(/ග‍්ගිං/g, "ggiṃ");
  105. txt = txt.replace(/ග‍්ගුං/g, "gguṃ");
  106. txt = txt.replace(/ග‍්ඝිං/g, "gghiṃ");
  107. txt = txt.replace(/ග‍්ඝුං/g, "gghuṃ");
  108. txt = txt.replace(/‍ය්‍ය/g, "yya");
  109. txt = txt.replace(/ක්කිං/g, "kkaṃ");
  110. txt = txt.replace(/ක්කුං/g, "kkiṃ");
  111. txt = txt.replace(/ක‍්කා/g, "kkā");
  112. txt = txt.replace(/ක‍්කි/g, "kki");
  113. txt = txt.replace(/ක‍්කී/g, "kkī");
  114. txt = txt.replace(/ක‍්කු/g, "kku");
  115. txt = txt.replace(/ක‍්කූ/g, "kkū");
  116. txt = txt.replace(/ක‍්කෙ/g, "kke");
  117. txt = txt.replace(/ක‍්කො/g, "kko");
  118. txt = txt.replace(/ක‍්කං/g, "kkaṃ");
  119. txt = txt.replace(/ක්ඛිං/g, "kkhiṃ");
  120. txt = txt.replace(/ක්ඛුං/g, "kkhuṃ");
  121. txt = txt.replace(/ක‍්ඛා/g, "kkhā");
  122. txt = txt.replace(/ක‍්ඛි/g, "kkhi");
  123. txt = txt.replace(/ක‍්ඛී/g, "kkhī");
  124. txt = txt.replace(/ක‍්ඛු/g, "kkhu");
  125. txt = txt.replace(/ක‍්ඛූ/g, "kkhū");
  126. txt = txt.replace(/ක‍්ඛෙ/g, "kkhe");
  127. txt = txt.replace(/ක‍්ඛො/g, "kkho");
  128. txt = txt.replace(/ක‍්ඛං/g, "kkhaṃ");
  129. txt = txt.replace(/ක්‍යා/g, "kyā");
  130. txt = txt.replace(/ක්‍යි/g, "kyi");
  131. txt = txt.replace(/ක්‍යී/g, "kyī");
  132. txt = txt.replace(/ක්‍යු/g, "kyu");
  133. txt = txt.replace(/ක්‍යූ/g, "kyū");
  134. txt = txt.replace(/ක්‍යෙ/g, "kye");
  135. txt = txt.replace(/ක්‍යො/g, "kyo");
  136. txt = txt.replace(/ක්‍යං/g, "kyaṃ");
  137. txt = txt.replace(/ක්‍යා/g, "kyā");
  138. txt = txt.replace(/ක්‍යි/g, "kyi");
  139. txt = txt.replace(/ක්‍යී/g, "kyī");
  140. txt = txt.replace(/ක්‍යු/g, "kyu");
  141. txt = txt.replace(/ක්‍යූ/g, "kyū");
  142. txt = txt.replace(/ක්‍යෙ/g, "kye");
  143. txt = txt.replace(/ක්‍යො/g, "kyo");
  144. txt = txt.replace(/ක්‍යං/g, "kyaṃ");
  145. txt = txt.replace(/ක්‍රා/g, "krā");
  146. txt = txt.replace(/ක්‍රි/g, "kri");
  147. txt = txt.replace(/ක්‍රී/g, "krī");
  148. txt = txt.replace(/ක්‍රු/g, "kru");
  149. txt = txt.replace(/ක්‍රූ/g, "krū");
  150. txt = txt.replace(/ක්‍රෙ/g, "kre");
  151. txt = txt.replace(/ක්‍රො/g, "kro");
  152. txt = txt.replace(/ක්‍රං/g, "kraṃ");
  153. txt = txt.replace(/ක්‍රා/g, "krā");
  154. txt = txt.replace(/ක්‍රි/g, "kri");
  155. txt = txt.replace(/ක්‍රී/g, "krī");
  156. txt = txt.replace(/ක්‍රු/g, "kru");
  157. txt = txt.replace(/ක්‍රූ/g, "krū");
  158. txt = txt.replace(/ක්‍රෙ/g, "kre");
  159. txt = txt.replace(/ක්‍රො/g, "kro");
  160. txt = txt.replace(/ක්‍රං/g, "kraṃ");
  161. txt = txt.replace(/ක්විං/g, "kviṃ");
  162. txt = txt.replace(/ක්වුං/g, "kvuṃ");
  163. txt = txt.replace(/ක්‍වා/g, "kvā");
  164. txt = txt.replace(/ක්‍වි/g, "kvi");
  165. txt = txt.replace(/ක්‍වී/g, "kvī");
  166. txt = txt.replace(/ක්‍වු/g, "kvu");
  167. txt = txt.replace(/ක්‍වූ/g, "kvū");
  168. txt = txt.replace(/ක්‍වෙ/g, "kve");
  169. txt = txt.replace(/ක්‍වො/g, "kvo");
  170. txt = txt.replace(/ක්‍වං/g, "kvaṃ");
  171. txt = txt.replace(/ඛ්‍යා/g, "khyā");
  172. txt = txt.replace(/ඛ්‍යි/g, "khyi");
  173. txt = txt.replace(/ඛ්‍යී/g, "khyī");
  174. txt = txt.replace(/ඛ්‍යු/g, "khyu");
  175. txt = txt.replace(/ඛ්‍යූ/g, "khyū");
  176. txt = txt.replace(/ඛ්‍යෙ/g, "khye");
  177. txt = txt.replace(/ඛ්‍යො/g, "khyo");
  178. txt = txt.replace(/ඛ්‍යං/g, "khyaṃ");
  179. txt = txt.replace(/ඛ‍්වා/g, "khvā");
  180. txt = txt.replace(/ඛ‍්වි/g, "khvi");
  181. txt = txt.replace(/ඛ‍්වී/g, "khvī");
  182. txt = txt.replace(/ඛ‍්වු/g, "khvu");
  183. txt = txt.replace(/ඛ‍්වූ/g, "khvū");
  184. txt = txt.replace(/ඛ‍්වෙ/g, "khve");
  185. txt = txt.replace(/ඛ‍්වො/g, "khvo");
  186. txt = txt.replace(/ඛ‍්වං/g, "khvaṃ");
  187. txt = txt.replace(/ග‍්ගා/g, "ggā");
  188. txt = txt.replace(/ග‍්ගි/g, "ggi");
  189. txt = txt.replace(/ග‍්ගී/g, "ggī");
  190. txt = txt.replace(/ග‍්ගු/g, "ggu");
  191. txt = txt.replace(/ග‍්ගූ/g, "ggū");
  192. txt = txt.replace(/ග‍්ගෙ/g, "gge");
  193. txt = txt.replace(/ග‍්ගො/g, "ggo");
  194. txt = txt.replace(/ග‍්ගං/g, "ggaṃ");
  195. txt = txt.replace(/ග‍්ඝා/g, "gghā");
  196. txt = txt.replace(/ග‍්ඝි/g, "gghi");
  197. txt = txt.replace(/ග‍්ඝී/g, "gghī");
  198. txt = txt.replace(/ග‍්ඝු/g, "gghu");
  199. txt = txt.replace(/ග‍්ඝූ/g, "gghū");
  200. txt = txt.replace(/ග‍්ඝෙ/g, "gghe");
  201. txt = txt.replace(/ග‍්ඝො/g, "ggho");
  202. txt = txt.replace(/ග‍්ඝං/g, "gghaṃ");
  203. txt = txt.replace(/ක්‍ර/g, "kra");
  204. txt = txt.replace(/ක්‍ය/g, "kya");
  205. txt = txt.replace(/ඛ්‍ර/g, "khra");
  206. txt = txt.replace(/ඛ්‍ය/g, "khya");
  207. txt = txt.replace(/ග්‍ර/g, "gra");
  208. txt = txt.replace(/ග්‍ය/g, "gya");
  209. txt = txt.replace(/ඝ්‍ර/g, "ghra");
  210. txt = txt.replace(/ඝ්‍ය/g, "ghya");
  211. txt = txt.replace(/ඞ්‍ර/g, "ṅra");
  212. txt = txt.replace(/ඞ්‍ය/g, "ṅya");
  213. txt = txt.replace(/ච්‍ර/g, "cra");
  214. txt = txt.replace(/ච්‍ය/g, "cya");
  215. txt = txt.replace(/ඡ්‍ර/g, "chra");
  216. txt = txt.replace(/ඡ්‍ය/g, "chya");
  217. txt = txt.replace(/ජ්‍ර/g, "jra");
  218. txt = txt.replace(/ජ්‍ය/g, "jya");
  219. txt = txt.replace(/ඣ්‍ර/g, "jhra");
  220. txt = txt.replace(/ඣ්‍ය/g, "jhya");
  221. txt = txt.replace(/ඤ්‍ර/g, "ñra");
  222. txt = txt.replace(/ඤ්‍ය/g, "ñya");
  223. txt = txt.replace(/ට්‍ර/g, "ṭra");
  224. txt = txt.replace(/ට්‍ය/g, "ṭya");
  225. txt = txt.replace(/ඨ්‍ර/g, "ṭhra");
  226. txt = txt.replace(/ඨ්‍ය/g, "ṭhya");
  227. txt = txt.replace(/ඩ්‍ර/g, "ḍra");
  228. txt = txt.replace(/ඩ්‍ය/g, "ḍya");
  229. txt = txt.replace(/ඪ්‍ර/g, "ḍhra");
  230. txt = txt.replace(/ඪ්‍ය/g, "ḍhya");
  231. txt = txt.replace(/ණ්‍ර/g, "ṇra");
  232. txt = txt.replace(/ණ්‍ය/g, "ṇya");
  233. txt = txt.replace(/ත්‍ර/g, "tra");
  234. txt = txt.replace(/ත්‍ය/g, "tya");
  235. txt = txt.replace(/ථ්‍ර/g, "thra");
  236. txt = txt.replace(/ථ්‍ය/g, "thya");
  237. txt = txt.replace(/ද්‍ර/g, "dra");
  238. txt = txt.replace(/ද්‍ය/g, "dya");
  239. txt = txt.replace(/ධ්‍ර/g, "dhra");
  240. txt = txt.replace(/ධ්‍ය/g, "dhya");
  241. txt = txt.replace(/න්‍ර/g, "nra");
  242. txt = txt.replace(/න්‍ය/g, "nya");
  243. txt = txt.replace(/ප්‍ර/g, "pra");
  244. txt = txt.replace(/ප්‍ය/g, "pya");
  245. txt = txt.replace(/ඵ්‍ර/g, "phra");
  246. txt = txt.replace(/ඵ්‍ය/g, "phya");
  247. txt = txt.replace(/බ්‍ර/g, "bra");
  248. txt = txt.replace(/බ්‍ය/g, "bya");
  249. txt = txt.replace(/භ්‍ර/g, "bhra");
  250. txt = txt.replace(/භ්‍ය/g, "bhya");
  251. txt = txt.replace(/ම්‍ර/g, "mra");
  252. txt = txt.replace(/ම්‍ය/g, "mya");
  253. txt = txt.replace(/‍යිං/g, "yiṃ");
  254. txt = txt.replace(/‍යුං/g, "yuṃ");
  255. txt = txt.replace(/‍රිං/g, "riṃ");
  256. txt = txt.replace(/‍රුං/g, "ruṃ");
  257. txt = txt.replace(/ල්‍ය/g, "lya");
  258. txt = txt.replace(/ව්‍ර/g, "vra");
  259. txt = txt.replace(/ව්‍ය/g, "vya");
  260. txt = txt.replace(/ස්‍ර/g, "sra");
  261. txt = txt.replace(/ස්‍ය/g, "sya");
  262. txt = txt.replace(/හ්‍ර/g, "hra");
  263. txt = txt.replace(/හ්‍ය/g, "hya");
  264. txt = txt.replace(/ළ්‍ය/g, "ḷya");
  265. txt = txt.replace(/ක්කා/g, "kka");
  266. txt = txt.replace(/ක්කි/g, "kkā");
  267. txt = txt.replace(/ක්කී/g, "kki");
  268. txt = txt.replace(/ක්කු/g, "kkī");
  269. txt = txt.replace(/ක්කූ/g, "kku");
  270. txt = txt.replace(/ක්කෙ/g, "kkū");
  271. txt = txt.replace(/ක්කො/g, "kke");
  272. txt = txt.replace(/ක්කං/g, "kko");
  273. txt = txt.replace(/ක‍්ක/g, "kka");
  274. txt = txt.replace(/ක්ඛා/g, "kkhā");
  275. txt = txt.replace(/ක්ඛි/g, "kkhi");
  276. txt = txt.replace(/ක්ඛී/g, "kkhī");
  277. txt = txt.replace(/ක්ඛු/g, "kkhu");
  278. txt = txt.replace(/ක්ඛූ/g, "kkhū");
  279. txt = txt.replace(/ක්ඛෙ/g, "kkhe");
  280. txt = txt.replace(/ක්ඛො/g, "kkho");
  281. txt = txt.replace(/ක්ඛං/g, "kkhaṃ");
  282. txt = txt.replace(/ක‍්ඛ/g, "kkha");
  283. txt = txt.replace(/ක්‍ය/g, "kya");
  284. txt = txt.replace(/ක්‍ය/g, "kya");
  285. txt = txt.replace(/ක්‍ර/g, "kra");
  286. txt = txt.replace(/ක්‍ර/g, "kra");
  287. txt = txt.replace(/ක්වා/g, "kvā");
  288. txt = txt.replace(/ක්වි/g, "kvi");
  289. txt = txt.replace(/ක්වී/g, "kvī");
  290. txt = txt.replace(/ක්වු/g, "kvu");
  291. txt = txt.replace(/ක්වූ/g, "kvū");
  292. txt = txt.replace(/ක්වෙ/g, "kve");
  293. txt = txt.replace(/ක්වො/g, "kvo");
  294. txt = txt.replace(/ක්වං/g, "kvaṃ");
  295. txt = txt.replace(/ක්‍ව/g, "kva");
  296. txt = txt.replace(/ඛ්‍ය/g, "khya");
  297. txt = txt.replace(/ඛ‍්ව/g, "khva");
  298. txt = txt.replace(/ග‍්ග/g, "gga");
  299. txt = txt.replace(/ග‍්ඝ/g, "ggha");
  300. txt = txt.replace(/කිං/g, "kiṃ");
  301. txt = txt.replace(/කුං/g, "kuṃ");
  302. txt = txt.replace(/ඛිං/g, "khiṃ");
  303. txt = txt.replace(/ඛුං/g, "khuṃ");
  304. txt = txt.replace(/ගිං/g, "giṃ");
  305. txt = txt.replace(/ගුං/g, "guṃ");
  306. txt = txt.replace(/ඝිං/g, "ghiṃ");
  307. txt = txt.replace(/ඝුං/g, "ghuṃ");
  308. txt = txt.replace(/ඞිං/g, "ṅiṃ");
  309. txt = txt.replace(/ඞුං/g, "ṅuṃ");
  310. txt = txt.replace(/චිං/g, "ciṃ");
  311. txt = txt.replace(/චුං/g, "cuṃ");
  312. txt = txt.replace(/ඡිං/g, "chiṃ");
  313. txt = txt.replace(/ඡුං/g, "chuṃ");
  314. txt = txt.replace(/ජිං/g, "jiṃ");
  315. txt = txt.replace(/ජුං/g, "juṃ");
  316. txt = txt.replace(/ඣිං/g, "jhiṃ");
  317. txt = txt.replace(/ඣුං/g, "jhuṃ");
  318. txt = txt.replace(/ඤිං/g, "ñiṃ");
  319. txt = txt.replace(/ඤුං/g, "ñuṃ");
  320. txt = txt.replace(/ටිං/g, "ṭiṃ");
  321. txt = txt.replace(/ටුං/g, "ṭuṃ");
  322. txt = txt.replace(/ඨිං/g, "ṭhiṃ");
  323. txt = txt.replace(/ඨුං/g, "ṭhuṃ");
  324. txt = txt.replace(/ඩිං/g, "ḍiṃ");
  325. txt = txt.replace(/ඩුං/g, "ḍuṃ");
  326. txt = txt.replace(/ඪිං/g, "ḍhiṃ");
  327. txt = txt.replace(/ඪුං/g, "ḍhuṃ");
  328. txt = txt.replace(/ණිං/g, "ṇiṃ");
  329. txt = txt.replace(/ණුං/g, "ṇuṃ");
  330. txt = txt.replace(/තිං/g, "tiṃ");
  331. txt = txt.replace(/තුං/g, "tuṃ");
  332. txt = txt.replace(/ථිං/g, "thiṃ");
  333. txt = txt.replace(/ථුං/g, "thuṃ");
  334. txt = txt.replace(/දිං/g, "diṃ");
  335. txt = txt.replace(/දුං/g, "duṃ");
  336. txt = txt.replace(/ධිං/g, "dhiṃ");
  337. txt = txt.replace(/ධුං/g, "dhuṃ");
  338. txt = txt.replace(/නිං/g, "niṃ");
  339. txt = txt.replace(/නුං/g, "nuṃ");
  340. txt = txt.replace(/පිං/g, "piṃ");
  341. txt = txt.replace(/පුං/g, "puṃ");
  342. txt = txt.replace(/ඵිං/g, "phiṃ");
  343. txt = txt.replace(/ඵුං/g, "phuṃ");
  344. txt = txt.replace(/බිං/g, "biṃ");
  345. txt = txt.replace(/බුං/g, "buṃ");
  346. txt = txt.replace(/භිං/g, "bhiṃ");
  347. txt = txt.replace(/භුං/g, "bhuṃ");
  348. txt = txt.replace(/මිං/g, "miṃ");
  349. txt = txt.replace(/මුං/g, "muṃ");
  350. txt = txt.replace(/‍යා/g, "yā");
  351. txt = txt.replace(/‍යි/g, "yi");
  352. txt = txt.replace(/‍යී/g, "yī");
  353. txt = txt.replace(/‍යු/g, "yu");
  354. txt = txt.replace(/‍යූ/g, "yū");
  355. txt = txt.replace(/‍යං/g, "yaṃ");
  356. txt = txt.replace(/‍රා/g, "rā");
  357. txt = txt.replace(/‍රි/g, "ri");
  358. txt = txt.replace(/‍රී/g, "rī");
  359. txt = txt.replace(/‍රු/g, "ru");
  360. txt = txt.replace(/‍රූ/g, "rū");
  361. txt = txt.replace(/‍රං/g, "raṃ");
  362. txt = txt.replace(/ලිං/g, "liṃ");
  363. txt = txt.replace(/ලුං/g, "luṃ");
  364. txt = txt.replace(/විං/g, "viṃ");
  365. txt = txt.replace(/වුං/g, "vuṃ");
  366. txt = txt.replace(/සිං/g, "siṃ");
  367. txt = txt.replace(/සුං/g, "suṃ");
  368. txt = txt.replace(/හිං/g, "hiṃ");
  369. txt = txt.replace(/හුං/g, "huṃ");
  370. txt = txt.replace(/ළිං/g, "ḷiṃ");
  371. txt = txt.replace(/ළුං/g, "ḷuṃ");
  372. txt = txt.replace(/ක්ක/g, "kk");
  373. txt = txt.replace(/ක්ඛ/g, "kkha");
  374. txt = txt.replace(/ක්ව/g, "kva");
  375. txt = txt.replace(/ක්/g, "k");
  376. txt = txt.replace(/කා/g, "kā");
  377. txt = txt.replace(/කි/g, "ki");
  378. txt = txt.replace(/කී/g, "kī");
  379. txt = txt.replace(/කු/g, "ku");
  380. txt = txt.replace(/කූ/g, "kū");
  381. txt = txt.replace(/කෙ/g, "ke");
  382. txt = txt.replace(/කො/g, "ko");
  383. txt = txt.replace(/කං/g, "kaṃ");
  384. txt = txt.replace(/ඛ්/g, "kh");
  385. txt = txt.replace(/ඛා/g, "khā");
  386. txt = txt.replace(/ඛි/g, "khi");
  387. txt = txt.replace(/ඛී/g, "khī");
  388. txt = txt.replace(/ඛු/g, "khu");
  389. txt = txt.replace(/ඛූ/g, "khū");
  390. txt = txt.replace(/ඛෙ/g, "khe");
  391. txt = txt.replace(/ඛො/g, "kho");
  392. txt = txt.replace(/ඛං/g, "khaṃ");
  393. txt = txt.replace(/ග්/g, "g");
  394. txt = txt.replace(/ගා/g, "gā");
  395. txt = txt.replace(/ගි/g, "gi");
  396. txt = txt.replace(/ගී/g, "gī");
  397. txt = txt.replace(/ගු/g, "gu");
  398. txt = txt.replace(/ගූ/g, "gū");
  399. txt = txt.replace(/ගෙ/g, "ge");
  400. txt = txt.replace(/ගො/g, "go");
  401. txt = txt.replace(/ගං/g, "gaṃ");
  402. txt = txt.replace(/ඝ්/g, "gh");
  403. txt = txt.replace(/ඝා/g, "ghā");
  404. txt = txt.replace(/ඝි/g, "ghi");
  405. txt = txt.replace(/ඝී/g, "ghī");
  406. txt = txt.replace(/ඝු/g, "ghu");
  407. txt = txt.replace(/ඝූ/g, "ghū");
  408. txt = txt.replace(/ඝෙ/g, "ghe");
  409. txt = txt.replace(/ඝො/g, "gho");
  410. txt = txt.replace(/ඝං/g, "ghaṃ");
  411. txt = txt.replace(/ඞ්/g, "ṅ");
  412. txt = txt.replace(/ඞා/g, "ṅā");
  413. txt = txt.replace(/ඞි/g, "ṅi");
  414. txt = txt.replace(/ඞී/g, "ṅī");
  415. txt = txt.replace(/ඞු/g, "ṅu");
  416. txt = txt.replace(/ඞූ/g, "ṅū");
  417. txt = txt.replace(/ඞෙ/g, "ṅe");
  418. txt = txt.replace(/ඞො/g, "ṅo");
  419. txt = txt.replace(/ඞං/g, "ṅaṃ");
  420. txt = txt.replace(/ච්/g, "c");
  421. txt = txt.replace(/චා/g, "cā");
  422. txt = txt.replace(/චි/g, "ci");
  423. txt = txt.replace(/චී/g, "cī");
  424. txt = txt.replace(/චු/g, "cu");
  425. txt = txt.replace(/චූ/g, "cū");
  426. txt = txt.replace(/චෙ/g, "ce");
  427. txt = txt.replace(/චො/g, "co");
  428. txt = txt.replace(/චං/g, "caṃ");
  429. txt = txt.replace(/ඡ්/g, "ch");
  430. txt = txt.replace(/ඡා/g, "chā");
  431. txt = txt.replace(/ඡි/g, "chi");
  432. txt = txt.replace(/ඡී/g, "chī");
  433. txt = txt.replace(/ඡු/g, "chu");
  434. txt = txt.replace(/ඡූ/g, "chū");
  435. txt = txt.replace(/ඡෙ/g, "che");
  436. txt = txt.replace(/ඡො/g, "cho");
  437. txt = txt.replace(/ඡං/g, "chaṃ");
  438. txt = txt.replace(/ජ්/g, "j");
  439. txt = txt.replace(/ජා/g, "jā");
  440. txt = txt.replace(/ජි/g, "ji");
  441. txt = txt.replace(/ජී/g, "jī");
  442. txt = txt.replace(/ජු/g, "ju");
  443. txt = txt.replace(/ජූ/g, "jū");
  444. txt = txt.replace(/ජෙ/g, "je");
  445. txt = txt.replace(/ජො/g, "jo");
  446. txt = txt.replace(/ජං/g, "jaṃ");
  447. txt = txt.replace(/ඣ්/g, "jh");
  448. txt = txt.replace(/ඣා/g, "jhā");
  449. txt = txt.replace(/ඣි/g, "jhi");
  450. txt = txt.replace(/ඣී/g, "jhī");
  451. txt = txt.replace(/ඣු/g, "jhu");
  452. txt = txt.replace(/ඣූ/g, "jhū");
  453. txt = txt.replace(/ඣෙ/g, "jhe");
  454. txt = txt.replace(/ඣො/g, "jho");
  455. txt = txt.replace(/ඣං/g, "jhaṃ");
  456. txt = txt.replace(/ඤ්/g, "ñ");
  457. txt = txt.replace(/ඤා/g, "ñā");
  458. txt = txt.replace(/ඤි/g, "ñi");
  459. txt = txt.replace(/ඤී/g, "ñī");
  460. txt = txt.replace(/ඤු/g, "ñu");
  461. txt = txt.replace(/ඤූ/g, "ñū");
  462. txt = txt.replace(/ඤෙ/g, "ñe");
  463. txt = txt.replace(/ඤො/g, "ño");
  464. txt = txt.replace(/ඤං/g, "ñaṃ");
  465. txt = txt.replace(/ට්/g, "ṭ");
  466. txt = txt.replace(/ටා/g, "ṭā");
  467. txt = txt.replace(/ටි/g, "ṭi");
  468. txt = txt.replace(/ටී/g, "ṭī");
  469. txt = txt.replace(/ටු/g, "ṭu");
  470. txt = txt.replace(/ටූ/g, "ṭū");
  471. txt = txt.replace(/ටෙ/g, "ṭe");
  472. txt = txt.replace(/ටො/g, "ṭo");
  473. txt = txt.replace(/ටං/g, "ṭaṃ");
  474. txt = txt.replace(/ඨ්/g, "ṭh");
  475. txt = txt.replace(/ඨා/g, "ṭhā");
  476. txt = txt.replace(/ඨි/g, "ṭhi");
  477. txt = txt.replace(/ඨී/g, "ṭhī");
  478. txt = txt.replace(/ඨු/g, "ṭhu");
  479. txt = txt.replace(/ඨූ/g, "ṭhū");
  480. txt = txt.replace(/ඨෙ/g, "ṭhe");
  481. txt = txt.replace(/ඨො/g, "ṭho");
  482. txt = txt.replace(/ඨං/g, "ṭhaṃ");
  483. txt = txt.replace(/ඩ්/g, "ḍ");
  484. txt = txt.replace(/ඩා/g, "ḍā");
  485. txt = txt.replace(/ඩි/g, "ḍi");
  486. txt = txt.replace(/ඩී/g, "ḍī");
  487. txt = txt.replace(/ඩු/g, "ḍu");
  488. txt = txt.replace(/ඩූ/g, "ḍū");
  489. txt = txt.replace(/ඩෙ/g, "ḍe");
  490. txt = txt.replace(/ඩො/g, "ḍo");
  491. txt = txt.replace(/ඩං/g, "ḍaṃ");
  492. txt = txt.replace(/ඪ්/g, "ḍh");
  493. txt = txt.replace(/ඪා/g, "ḍhā");
  494. txt = txt.replace(/ඪි/g, "ḍhi");
  495. txt = txt.replace(/ඪී/g, "ḍhī");
  496. txt = txt.replace(/ඪු/g, "ḍhu");
  497. txt = txt.replace(/ඪූ/g, "ḍhū");
  498. txt = txt.replace(/ඪෙ/g, "ḍhe");
  499. txt = txt.replace(/ඪො/g, "ḍho");
  500. txt = txt.replace(/ඪං/g, "ḍhaṃ");
  501. txt = txt.replace(/ණ්/g, "ṇ");
  502. txt = txt.replace(/ණා/g, "ṇā");
  503. txt = txt.replace(/ණි/g, "ṇi");
  504. txt = txt.replace(/ණී/g, "ṇī");
  505. txt = txt.replace(/ණු/g, "ṇu");
  506. txt = txt.replace(/ණූ/g, "ṇū");
  507. txt = txt.replace(/ණෙ/g, "ṇe");
  508. txt = txt.replace(/ණො/g, "ṇo");
  509. txt = txt.replace(/ණං/g, "ṇaṃ");
  510. txt = txt.replace(/ත්/g, "t");
  511. txt = txt.replace(/තා/g, "tā");
  512. txt = txt.replace(/ති/g, "ti");
  513. txt = txt.replace(/තී/g, "tī");
  514. txt = txt.replace(/තු/g, "tu");
  515. txt = txt.replace(/තූ/g, "tū");
  516. txt = txt.replace(/තෙ/g, "te");
  517. txt = txt.replace(/තො/g, "to");
  518. txt = txt.replace(/තං/g, "taṃ");
  519. txt = txt.replace(/ථ්/g, "th");
  520. txt = txt.replace(/ථා/g, "thā");
  521. txt = txt.replace(/ථි/g, "thi");
  522. txt = txt.replace(/ථී/g, "thī");
  523. txt = txt.replace(/ථු/g, "thu");
  524. txt = txt.replace(/ථූ/g, "thū");
  525. txt = txt.replace(/ථෙ/g, "the");
  526. txt = txt.replace(/ථො/g, "tho");
  527. txt = txt.replace(/ථං/g, "thaṃ");
  528. txt = txt.replace(/ද්/g, "d");
  529. txt = txt.replace(/දා/g, "dā");
  530. txt = txt.replace(/දි/g, "di");
  531. txt = txt.replace(/දී/g, "dī");
  532. txt = txt.replace(/දු/g, "du");
  533. txt = txt.replace(/දූ/g, "dū");
  534. txt = txt.replace(/දෙ/g, "de");
  535. txt = txt.replace(/දො/g, "do");
  536. txt = txt.replace(/දං/g, "daṃ");
  537. txt = txt.replace(/ධ්/g, "dh");
  538. txt = txt.replace(/ධා/g, "dhā");
  539. txt = txt.replace(/ධි/g, "dhi");
  540. txt = txt.replace(/ධී/g, "dhī");
  541. txt = txt.replace(/ධු/g, "dhu");
  542. txt = txt.replace(/ධූ/g, "dhū");
  543. txt = txt.replace(/ධෙ/g, "dhe");
  544. txt = txt.replace(/ධො/g, "dho");
  545. txt = txt.replace(/ධං/g, "dhaṃ");
  546. txt = txt.replace(/න්/g, "n");
  547. txt = txt.replace(/නා/g, "nā");
  548. txt = txt.replace(/නි/g, "ni");
  549. txt = txt.replace(/නී/g, "nī");
  550. txt = txt.replace(/නු/g, "nu");
  551. txt = txt.replace(/නූ/g, "nū");
  552. txt = txt.replace(/නෙ/g, "ne");
  553. txt = txt.replace(/නො/g, "no");
  554. txt = txt.replace(/නං/g, "naṃ");
  555. txt = txt.replace(/ප්/g, "p");
  556. txt = txt.replace(/පා/g, "pā");
  557. txt = txt.replace(/පි/g, "pi");
  558. txt = txt.replace(/පී/g, "pī");
  559. txt = txt.replace(/පු/g, "pu");
  560. txt = txt.replace(/පූ/g, "pū");
  561. txt = txt.replace(/පෙ/g, "pe");
  562. txt = txt.replace(/පො/g, "po");
  563. txt = txt.replace(/පං/g, "paṃ");
  564. txt = txt.replace(/ඵ්/g, "ph");
  565. txt = txt.replace(/ඵා/g, "phā");
  566. txt = txt.replace(/ඵි/g, "phi");
  567. txt = txt.replace(/ඵී/g, "phī");
  568. txt = txt.replace(/ඵු/g, "phu");
  569. txt = txt.replace(/ඵූ/g, "phū");
  570. txt = txt.replace(/ඵෙ/g, "phe");
  571. txt = txt.replace(/ඵො/g, "pho");
  572. txt = txt.replace(/ඵං/g, "phaṃ");
  573. txt = txt.replace(/බ්/g, "b");
  574. txt = txt.replace(/බා/g, "bā");
  575. txt = txt.replace(/බි/g, "bi");
  576. txt = txt.replace(/බී/g, "bī");
  577. txt = txt.replace(/බු/g, "bu");
  578. txt = txt.replace(/බූ/g, "bū");
  579. txt = txt.replace(/බෙ/g, "be");
  580. txt = txt.replace(/බො/g, "bo");
  581. txt = txt.replace(/බං/g, "baṃ");
  582. txt = txt.replace(/භ්/g, "bh");
  583. txt = txt.replace(/භා/g, "bhā");
  584. txt = txt.replace(/භි/g, "bhi");
  585. txt = txt.replace(/භී/g, "bhī");
  586. txt = txt.replace(/භු/g, "bhu");
  587. txt = txt.replace(/භූ/g, "bhū");
  588. txt = txt.replace(/භෙ/g, "bhe");
  589. txt = txt.replace(/භො/g, "bho");
  590. txt = txt.replace(/භං/g, "bhaṃ");
  591. txt = txt.replace(/ම්/g, "m");
  592. txt = txt.replace(/මා/g, "mā");
  593. txt = txt.replace(/මි/g, "mi");
  594. txt = txt.replace(/මී/g, "mī");
  595. txt = txt.replace(/මු/g, "mu");
  596. txt = txt.replace(/මූ/g, "mū");
  597. txt = txt.replace(/මෙ/g, "me");
  598. txt = txt.replace(/මො/g, "mo");
  599. txt = txt.replace(/මං/g, "maṃ");
  600. txt = txt.replace(/ය්/g, "y");
  601. txt = txt.replace(/‍ය/g, "ya");
  602. txt = txt.replace(/යෙ/g, "ye");
  603. txt = txt.replace(/යො/g, "yo");
  604. txt = txt.replace(/ර්/g, "r");
  605. txt = txt.replace(/‍ර/g, "ra");
  606. txt = txt.replace(/රෙ/g, "re");
  607. txt = txt.replace(/රො/g, "ro");
  608. txt = txt.replace(/ල්/g, "l");
  609. txt = txt.replace(/ලා/g, "lā");
  610. txt = txt.replace(/ලි/g, "li");
  611. txt = txt.replace(/ලී/g, "lī");
  612. txt = txt.replace(/ලු/g, "lu");
  613. txt = txt.replace(/ලූ/g, "lū");
  614. txt = txt.replace(/ලෙ/g, "le");
  615. txt = txt.replace(/ලො/g, "lo");
  616. txt = txt.replace(/ලං/g, "laṃ");
  617. txt = txt.replace(/ව්/g, "v");
  618. txt = txt.replace(/වා/g, "vā");
  619. txt = txt.replace(/වි/g, "vi");
  620. txt = txt.replace(/වී/g, "vī");
  621. txt = txt.replace(/වු/g, "vu");
  622. txt = txt.replace(/වූ/g, "vū");
  623. txt = txt.replace(/වෙ/g, "ve");
  624. txt = txt.replace(/වො/g, "vo");
  625. txt = txt.replace(/වං/g, "vaṃ");
  626. txt = txt.replace(/ස්/g, "s");
  627. txt = txt.replace(/සා/g, "sā");
  628. txt = txt.replace(/සි/g, "si");
  629. txt = txt.replace(/සී/g, "sī");
  630. txt = txt.replace(/සු/g, "su");
  631. txt = txt.replace(/සූ/g, "sū");
  632. txt = txt.replace(/සෙ/g, "se");
  633. txt = txt.replace(/සො/g, "so");
  634. txt = txt.replace(/සං/g, "saṃ");
  635. txt = txt.replace(/හ්/g, "h");
  636. txt = txt.replace(/හා/g, "hā");
  637. txt = txt.replace(/හි/g, "hi");
  638. txt = txt.replace(/හී/g, "hī");
  639. txt = txt.replace(/හු/g, "hu");
  640. txt = txt.replace(/හූ/g, "hū");
  641. txt = txt.replace(/හෙ/g, "he");
  642. txt = txt.replace(/හො/g, "ho");
  643. txt = txt.replace(/හං/g, "haṃ");
  644. txt = txt.replace(/ළ්/g, "ḷ");
  645. txt = txt.replace(/ළා/g, "ḷā");
  646. txt = txt.replace(/ළි/g, "ḷi");
  647. txt = txt.replace(/ළී/g, "ḷī");
  648. txt = txt.replace(/ළු/g, "ḷu");
  649. txt = txt.replace(/ළූ/g, "ḷū");
  650. txt = txt.replace(/ළෙ/g, "ḷe");
  651. txt = txt.replace(/ළො/g, "ḷo");
  652. txt = txt.replace(/ළං/g, "ḷaṃ");
  653. txt = txt.replace(/අ/g, "a");
  654. txt = txt.replace(/ආ/g, "ā");
  655. txt = txt.replace(/ඉ/g, "i");
  656. txt = txt.replace(/ඊ/g, "ī");
  657. txt = txt.replace(/උ/g, "u");
  658. txt = txt.replace(/ඌ/g, "ū");
  659. txt = txt.replace(/එ/g, "e");
  660. txt = txt.replace(/ඔ/g, "o");
  661. txt = txt.replace(/ක/g, "ka");
  662. txt = txt.replace(/ඛ/g, "kha");
  663. txt = txt.replace(/ග/g, "ga");
  664. txt = txt.replace(/ඝ/g, "gha");
  665. txt = txt.replace(/ඞ/g, "ṅa");
  666. txt = txt.replace(/ච/g, "ca");
  667. txt = txt.replace(/ඡ/g, "cha");
  668. txt = txt.replace(/ජ/g, "ja");
  669. txt = txt.replace(/ඣ/g, "jha");
  670. txt = txt.replace(/ඤ/g, "ña");
  671. txt = txt.replace(/ට/g, "ṭa");
  672. txt = txt.replace(/ඨ/g, "ṭha");
  673. txt = txt.replace(/ඩ/g, "ḍa");
  674. txt = txt.replace(/ඪ/g, "ḍha");
  675. txt = txt.replace(/ණ/g, "ṇa");
  676. txt = txt.replace(/ත/g, "ta");
  677. txt = txt.replace(/ථ/g, "tha");
  678. txt = txt.replace(/ද/g, "da");
  679. txt = txt.replace(/ධ/g, "dha");
  680. txt = txt.replace(/න/g, "na");
  681. txt = txt.replace(/ප/g, "pa");
  682. txt = txt.replace(/ඵ/g, "pha");
  683. txt = txt.replace(/බ/g, "ba");
  684. txt = txt.replace(/භ/g, "bha");
  685. txt = txt.replace(/ම/g, "ma");
  686. txt = txt.replace(/ල/g, "la");
  687. txt = txt.replace(/ව/g, "va");
  688. txt = txt.replace(/ස/g, "sa");
  689. txt = txt.replace(/හ/g, "ha");
  690. txt = txt.replace(/ළ/g, "ḷa");
  691. //replace end
  692. }
  693. catch (err) {
  694. //error
  695. alert(err.message);
  696. }
  697. document.getElementById("txtOutput").value = txt;
  698. }
  699. </script>
  700. <style>
  701. .bg0 {
  702. background-color: #FF9;
  703. }
  704. .bg1 {
  705. background-color: #AAA;
  706. }
  707. </style>
  708. </head>
  709. <body class="mainbody" id="mbody">
  710. <!-- tool bar begin-->
  711. <div class='toolbar'>
  712. <script language="javascript">
  713. if (!g_is_mobile) {
  714. document.write("<button id=\"B_Navi\" onclick=\"setNaviVisibility()\" type=\"button\">≡</button> ");
  715. }
  716. </script>
  717. <button id="menu_button_home" onclick="goHome()" type="button">Home</button>
  718. <button id="B_FontReduce" type="button" onclick="setPageFontSize(0.9)">A-</button>
  719. <button id="B_FontGain" type="button" onclick="setPageFontSize(1.1)">A+</button>
  720. <button id="B_Day" type="button" onclick="setPageColor(0)">白色</button>
  721. <button id="B_Sunset" type="button" onclick="setPageColor(1)">黄昏</button>
  722. <button id="B_Night" type="button" onclick="setPageColor(2)">夜间</button>
  723. <script language="javascript">
  724. </script>
  725. <span id="debug"></span>
  726. </div>
  727. <!--tool bar end -->
  728. <div class="main">
  729. <p><textarea id="txtInput" rows="30" cols="80"></textarea></p>
  730. <button id="file_new" type="button" onclick="s2u()">Sangayana To Unicode</button>
  731. <button id="file_new" type="button" onclick="u2s()">Unicode To Sangayana</button>
  732. <select id="m_str">
  733. <option value="ṃ,Ṃ">ṃ</option>
  734. <option value="ṁ,Ṁ">ṁ</option>
  735. <option value="ŋ,Ŋ">ŋ</option>
  736. </select>
  737. <button id="file_new" type="button" onclick="sinhala()">Sinhala To English</button>
  738. <p><textarea id="txtOutput" rows="30" cols="80"></textarea></p>
  739. <div class="debugMsg" id="xmldata">
  740. <!--调试信息-->
  741. </div>
  742. <!--right side end-->
  743. </div>
  744. <div id="modifywin">
  745. </div>
  746. </body>
  747. </html>