2012-02-01 48 views
-1

我在MySQL中有一行的值叫做($)lesson_title ...我希望這個值是由頭文件發送的FPDF生成的PDF文件的文件名,而不是通用的文件名。以下是在pdf.php文件頭目前發送:來自MySQL的文件名字段值

/* 
* Write PDF content to file. 
*/ 
$pdf->Output($lessonPlanFile, 'F') ; 
header('Content-type: application/pdf'); 
header('Content-Disposition: attachment; filename="My_Lesson_Plan.pdf"'); 

其中「My_Lesson_Plan.pdf」應該是$ lesson_title

聽起來很簡單,我已經嘗試了不少東西但無法獲得正確的語法。 = /上串插

回答

相關問題