forked from emaijala/MLInvoice
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinvoice_printer_finvoice_soap.php
More file actions
42 lines (34 loc) · 1.44 KB
/
invoice_printer_finvoice_soap.php
File metadata and controls
42 lines (34 loc) · 1.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
/*******************************************************************************
MLInvoice: web-based invoicing application.
Copyright (C) 2010-2016 Ere Maijala
This program is free software. See attached LICENSE.
*******************************************************************************/
/*******************************************************************************
MLInvoice: web-pohjainen laskutusohjelma.
Copyright (C) 2010-2016 Ere Maijala
Tämä ohjelma on vapaa. Lue oheinen LICENSE.
*******************************************************************************/
require_once 'invoice_printer_xslt.php';
require_once 'htmlfuncs.php';
require_once 'miscfuncs.php';
class InvoicePrinterFinvoiceSOAP extends InvoicePrinterXSLT
{
public function printInvoice()
{
// First create the actual Finvoice
$this->xsltParams['printTransmissionDetails'] = true;
parent::transform('create_finvoice.xsl', 'Finvoice.xsd');
$finvoice = $this->xml;
// Create the SOAP envelope
parent::transform('create_finvoice_soap_envelope.xsl');
header('Content-Type: text/xml; charset=ISO-8859-15');
$filename = $this->getPrintoutFileName();
if ($this->printStyle) {
header("Content-Disposition: inline; filename=$filename");
} else {
header("Content-Disposition: attachment; filename=$filename");
}
echo $this->xml . "\n$finvoice";
}
}