|
 |
|
สอบถามเรื่อง MPDF PHP หน่อยครับ ผมติดตั้งผ่าน composer พอจะนำมาใช้ กับ Error Undefined type Mpdf\Mpdf.intelephense(1009) |
|
 |
|
|
 |
 |
|
มันหา namespace ไม่เจอ
ลองเช็ค document ตามเวอร์ชันที่ใช้ (6.x/7.x ดูให้ชัด)
หรือ path ตอน include file
และลองค้นตาม framework(ถ้ามี)
เพราะจะมีรายละเอียดต่างกันตามเอกสารการใช้งาน
ตัวอย่างวิธีติดตั้งและใช้งานสำหรับ laravel
https://bestofphp.com/repo/mccarlosen-laravel-mpdf
|
 |
 |
 |
 |
Date :
2022-03-12 20:59:18 |
By :
009 |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
https://stackoverflow.com/a/59266972/128761
มันเป็นปัญหาของ Intelliphense บน Visual Studio Code.
ผมก็มีปัญหาเดียวกันกับระบบอื่นๆ เช่น WordPress เป็นต้น.
ต้องถามจขกท.ว่าจะให้ความสำคัญกับอะไร? กับการแจ้งบน editor หรือกับการทดลองรันจริงๆ
ถ้าอย่างหลังก็ไม่ต้องไปสนใจมัน หรือไปปรับตามที่ในลิ้งค์บอกไว้ เพราะมันเป็นปัญหาที่ดูงี่เง่าเกินกว่าจะมาเสียเวลาแล้วก็แก้ไม่ได้
ปัจจุบันผมใช้ Netbeans เป็นหลัก ก็ไม่เคยเจอปัญหานี้เลย แค่กำหนด folder ที่จะต้องใช้ใน included ก็พอ เช่นมีติดตั้ง WordPress เอาไว้แบบเดิมๆไม่ลงอะไร แล้วก็ include folder นั้น เวลาเรียกใช้ function มันก็จะมี helper ขึ้นมาให้ดูด้วย กด CTRL+click ตามดูได้ด้วย
แต่พอเป็น VS Code ไม่สามาารถหาวิธีแก้ได้ก็ต้องทำตามในลิ้งค์แนะนำ หรือช่างหัวมันไปเลย ไปดูผลตอนทดลองรันจริงๆเอาเอง.
แต่ถ้าจะเอาอย่างแรก ให้ความสำคัญกับการแจ้งบน editor เป็นหลัก ก็ต้องหาวิธีกันต่อไป
|
 |
 |
 |
 |
Date :
2022-03-13 18:09:39 |
By :
mr.v |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
ขอบคุณท่านทั้งสองมากครับ เดียวจะลองไปแก้ดูครับ
|
 |
 |
 |
 |
Date :
2022-03-14 15:23:36 |
By :
adminliver |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
|
|
|

|
Load balance : Server 03
|