Reputation: 59
Some of the Arabic characters are not displaying in PDF. Do I need to add any font in ColdFusion Administrator I gave المينــاء as input inside the tag CFDOCUMENT to show in PDF format.
In PDF, the output I am getting is اينــاء instead of المينــاء.
Please advice. Thanks in advance.
Upvotes: 0
Views: 433
Reputation: 21
got to c:/ drive >> windows folder >> fonts
check sure arial unicode ms is there if not there please add arial unicode ms.ttf
and inside CFML/HTML code please use like this style="font-family:arial unicode ms بيالتلان
Upvotes: 2
Reputation: 1741
You can use fontembed
attribute of cfdocument
and set it to true
to embed the specified fonts in the output. You need to wrap your text inside span
and specify the suitable font-family
(font-family that displays your text better as required) in its style
attribute. As @bibin suggested use Arial Unicode MS
as the font-family
.
Like this:
<cfdocument format="PDF" overwrite="true" fontembed="true">
<span style="font-size:20pt;font-family:Arial Unicode MS;">
المينــاء
</span>
</cfdocument>
Another font-family
able to display the text is Traditional Arabic
.
You can install other more accurate font in CF Admin if you find one, and use it as a font family.
Update:
In my case the font is already available in CF Admin. So here fontEmbed
is not really needed. It is helpful in case the font is not available in CF Admin and we want to use the font directly from CF page.
Upvotes: 3