File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -14,19 +14,18 @@ Ministerul de Finanțe pune la dispoziție o ["aplicație"](https://www.anaf.ro/
14
14
``` php
15
15
<?php
16
16
17
- require_once('tcpdf/tcpdf.php');
17
+ require_once('tcpdf/tcpdf.php'); // https://github.com/tecnickcom/tcpdf
18
+ require_once('fpdi/src/autoload.php'); // este opțional dacă se dorește includerea anexelor în format PDF (https://github.com/Setasign/FPDI)
18
19
require_once('xml2pdf.php');
19
20
20
- $xmlString=file_get_contents('factura .xml');
21
+ $xmlString=file_get_contents('exemplu .xml');
21
22
$factura=xml2pdfParse($xmlString);
22
23
23
24
if ($factura===false) {
24
25
exit('Eroare la parcurgerea fișierului XML.');
25
26
}
26
27
27
- $r=xml2pdfRender($factura,true);
28
- header("Content-type:application/pdf");
29
- echo $r;
28
+ xml2pdfRender($factura,false,'factura {{furnizor}} ({{numar}} din {{data}})');
30
29
31
30
?>
32
31
```
You can’t perform that action at this time.
0 commit comments