CSV to PDF Convert csv to pdf

You can directly convert CSV to PDF by passing the csv file. It will automatically convert csv to pdf. You can also define style, class etc optional parameter as 2nd argument.

                            $xinvoice = new Xinvoice();
                             //convert csv to pdf - complete physical path to csv file 
                             //e.g E:/xampp/htdocs/xinvoice/script/downloads/test.csv
                            echo $xinvoice->csvToPDF(XInvoiceABSPATH."downloads/file.csv");
                            // optional parameter to define style, class etc
                            //echo $xinvoice->csvToPDF(XInvoiceABSPATH."downloads/file.csv", array("style" => "'border: 1px solid #000'"));