រំលងទៅមាតិកា

កម្ពុជាត្រូវការសន្តិភាព / Cambodia needs peace

1 នាទីអាន 6Laravel
PHPPDF

Laravel Snappy — Khmer Unicode Support

To generate the pdf file with the Laravel framework, most developers will use barryvdh/laravel-snappy.

Laravel Snappy — Khmer Unicode Support

To generate the pdf file with the Laravel framework, most developers will use barryvdh/laravel-snappy.

Step 1: Copying Khmer Fonts on Linux

We need to copy the Khmer TTF file font from your local machine to your Ubuntu server by using this command

scp ~/Downloads/KhmerMEF1.ttf user@IP_ADDRESS:/home/user

Step 2: Install Khmer Fonts on Linux

After you copied the font to the server, you need to move it to /usr/share/fonts/truetype directory.

After that, you need to clear and regenerate your font cache by using this command

fc-list -f -v

Setp3: Call and use it

Finally, you can use it in the laravel-snappy by writing a simple CSS stylesheet.

font-family: 'KhmerMEF1', serif !important;

ចែករំលែកអត្ថបទនេះ

XLinkedIn

© 2026 Hel Mab. រក្សាសិទ្ធិគ្រប់យ៉ាង.

ភ្នំពេញ កម្ពុជា/បង្កើតដោយ Nuxt