PDF Print to folder
Hi I have setup weberp to print pdf flies to a folder in the class.pdf.php with this code
function OutputF($DocumentFilename = 'Document.pdf') {
if (($DocumentFilename == null) or ($DocumentFilename == '')) {
$DocumentFilename = _('Document.pdf');
}
$this->Output('C:/inetpub/webERP/docs/' . $DocumentFilename, 'F');
This works all well but what I would like to do is have each document print to different folders like invoices go to a invoices folder.
So in PrintCustTransPortrait.php around line 544 is
$pdf->OutputF($_SESSION['DatabaseName'] . '_' . $InvOrCredit . '_' . $FromTransNo . '.pdf');
I have added this line
$this->Output('C:/inetpub/webERP/docs/invoices/' . $DocumentFilename, 'F');
}
And I am getting errors.
Any help would be greatly appreciated.
Thanks
Dave
|