May 15

วิธีสร้าง PDF File ภาษาไทย

  1. http://www.thai-programmer.com/?DPage=25
  2. http://www.ros.co.nz/pdf/
  3. http://www.morelightmorelight.com/projects/walletpdf/
  4. http://www.fpdf.org/ | http://www.fpdf.org/phorum/read.php?f=1&i=5090&t=4996#5090
  5. http://www.setasign.de/products/pdf-php-solutions/fpdi/

=====================================

แหล่งข้อมูล: ไม่ทราบแหล่งที่มา (ใครเป็นเจ้าของช่วยบอกด้วยฮะ)

ให้ดาวน์โหลดตัวที่สร้าง font ก่อน จากที่นี่

http://www.fpdf.org/fr/dl.php?id=22
ให้ดาวน์โหลด cp874.map กับ iso-8859-11.map

หลังจากนั้นจะได้ไฟล์ exe มา 1 ตัว ให้เข้า dos รันมันขึ้นมา โดย
ใส่ parameter ตามนี้ อย่าไปคลิกที่ตัวมันนะ เพราะต้องใส่ parameter

ttf2pt1 -b -L cp874.map angsa.ttf angsa

ตรง angsa.ttf angsa ก็แล้วแต่ font ที่ท่านต้องการจะสร้างว่าต้องการใช้ font อะไรบ้าง

angsa.ttf เป็น font ใน windows เราอ่ะครับ ไป copy มาก็ได้ จะได้ไม่ต้องใส่ path
angsa คือชื่อที่เราจะตั้ง

หลังจากนั้นจะได้ ไฟล์มา 2 ตัว คือ
angsa.afm กับ angsa.pfb

หลังจากนั้น copy ทั้งสองตัวไปที่ /font/makefont
แล้วเขียน ไฟล์ php ตัวนึง ชื่ออะไรก็ได้ เพื่อรัน makefont.php ดังนี้

MakeFont('angsa.pfb','angsa.afm','cp874');

จะได้ file 2ตัวออกมา angsa.php and angsa.z

copy ไปวางที่ /font
ใช้คำสั่ง addfont

$pdf->AddFont('angsa','','angsa.php');


Posted by Scalopus+

Defined tags for this entry: ,

Last modified on 2008-05-15 21:11

0 Trackbacks

  1. No Trackbacks

0 Comments

Display comments as(Linear | Threaded)
  1. No comments

Add Comment


Enclosing asterisks marks text as bold (*word*), underscore are made via _word_.
Standard emoticons like :-) and ;-) are converted to images.
E-Mail addresses will not be displayed and will only be used for E-Mail notifications

To prevent automated Bots from commentspamming, please enter the string you see in the image below in the appropriate input box. Your comment will only be submitted if the strings match. Please ensure that your browser supports and accepts cookies, or your comment cannot be verified correctly.
CAPTCHA