如何将高棉Unicode字体转换为wordpress发布标题和内容的转义? 然后unescapes从那里在网站上显示原始的高棉语Unicode? 我使用了NewsPlus wordpress主题 最好的问候
答案 0 :(得分:0)
由于你从未提供过编程语言,我会假设Python 2.7,因为这会使问题变得微不足道。
>>> a = 'ភ្នំពេញ៖ តារាសម្ដែងស្រីថ្មី ក្នុងរូបភាពឆ្នាស់ឆ្នើម'
>>> print a.encode('unicode-escape')
\u1797\u17d2\u1793\u17c6\u1796\u17c1\u1789\u17d6 \u178f\u17b6\u179a\u17b6\u179f\u1798\u17d2\u178a\u17c2\u1784\u179f\u17d2\u179a\u17b8\u1790\u17d2\u1798\u17b8 \u1780\u17d2\u1793\u17bb\u1784\u179a\u17bc\u1794\u1797\u17b6\u1796\u1786\u17d2\u1793\u17b6\u179f\u17cb\u1786\u17d2\u1793\u17be\u1798