rohit mishra rohit mishra - 10 months ago 54
SQL Question

storing fpdf output in server and add filename in database

I am generating invoices using fpdf library which fetches data from database,now when the pdf is generated i want to save the file in a folder and add the file name with date in database so that i can fetch the all invoices generated previously in a table.Please help me out here.


Be shure that you can write to the directory.


Save the Pdf.


Update the Sql Tables

$query=" UPDATE `shopdb`.`bills` SET `bill_doc_crea` = '1', `bill_pdf_doc` = '".$filename."' WHERE `bills`.`ordernummer` ='".$orderId."' ;";