Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to display content for websites in Myanmar/Burmese font

I have a website which serves the Burmese people in burmese language. Problem is in Myanmar country Unicode format is not used instead they use Zawgyi format of encoding. The content on my website appears broken. How do I fix this issue.

enter image description here

This error is occuring in Iphones only

like image 416
SONGSTER Avatar asked Jul 07 '18 12:07

SONGSTER


People also ask

How can I change Myanmar typing?

Click Start, type inetcpl. cpl and hit enter. b. Click General tab, under Appearance click Fonts button.

What is the difference between zawgyi and Unicode?

Insert Zawgyi The concept is similar to Unicode. Except Zawgyi is only used for Burmese characters in the Burmese language. For both types of encoding, they can only be used with fonts that are compliant. With Unicode, this is easy, as it's an international standard.

What font is Myanmar?

There are lots of Myanmar fonts available for free. One of the most popular fonts was Zawgyi font.It was called Zawgyi One font. Other popular and free Myanmar unicode fonts are Pyidaungsu Font, Myanmar 3 Font and Myanmar Padauk Font.

Who invented Zawgyi font?

Zawgyi developer U Ye Myat Thu said that when the first Zawgyi font was released in 2006 “the Unicode version at the time, 4.1, was not able to support the consonant medial ya, ra, wa, and ha sounds”.


2 Answers

You can use font link and embed with font-family.All fonts correctly appear in any device or browser no need to put or install specific fonts in it's device.If you want to check another Myanmar fonts link.You can go there https://mmwebfonts.comquas.com/#how-to-use

<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<link rel="stylesheet" href='https://mmwebfonts.comquas.com/fonts/?font=myanmar3' />
	<link rel="stylesheet" href='https://mmwebfonts.comquas.com/fonts/?font=zawgyi' />	
	<style type="text/css">
		.zawgyi{
			font-family:Zawgyi-One;
		}
		.unicode{
			font-family:Myanmar3,Yunghkio,'Masterpiece Uni Sans';
		}
	</style>
</head>
<body>
	<h3>This is for ZawGyI font</h3>
	<p class="zawgyi">
		သည္စာသည္ ေဇာ္ဂ်ီ ျဖင့္ေရးေသာစာျဖစ္သည္
	</p>
	<h3>This is for unicode (myanmar3) font</h3>
	<p class="unicode">
		သည်စာသည် unicode ဖြင့်ရေးသောစာဖြစ်သည်
	</p>
</body>
</html>
like image 188
NayDwe Avatar answered Oct 15 '22 00:10

NayDwe


knayi is a good library to convert or detect (Unicode & Zawgyi) fonts.

You can load the script via CDN or NPM and use kanayi.fontConvert();


// Expected paramaters
kanayi.fontConvert(content, targetFontType , orignalFontType)


Example

knayi.fontConvert('မဂၤလာပါ', 'unicode', 'zawgyi') // မင်္ဂလာပါ
knayi.fontConvert('မဂၤလာပါ', 'unicode') // မင်္ဂလာပါ

Btw, I made a wordpress widget with kanayi.
https://github.com/ronaldaug/auto-font

like image 44
ronaldtgi Avatar answered Oct 14 '22 23:10

ronaldtgi