Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines
If you have problem with finding the correct path for phantomjs file please try to set its path directly like this:
$report->run()->export("MyReportPDF")
->settings([
'phantomjs' => $pathToPhantomjs //e.g: "/home/user/bin/phantomjs"
])
->pdf(...)
If it's a linux version, please remember the path must be case sensitively correct as well. Let us know the result. Thanks!
We are using laravel version 6.x
$report = new Supplierconnection();
$report->run()->export('SupplierconnectionPdf')->settings(array(
"useLocalTempFolder" => true
))->pdf(array(
"format" => "A4",
"orientation" => "landscap"
))->toBrowser("supplier_connection_" . date('Y-m-d') . ".pdf", true);
when i tried in my local machine than PDF got blank..
i already placed phantomjs in vendor/koolreport/export/bin
Export Function
$report = new Customersalesdeal();
$report->run()
->export('CustomersalesdealPdf')
->settings(array(
"useLocalTempFolder" => true,
"resourceWaiting" => 2000,
))
->pdf(array(
"format" => "A3",
"orientation" => "landscape",
//"zoom"=>2
))
->toBrowser("Customer_salesDeal" . date('Y-m-d') . ".pdf");
My PDF view page
<?php
use \koolreport\widgets\koolphp\Table;
?>
<html>
<head>Report</head>
<body style="margin:0.5in 1in 0.5in 1in">
<div class="page-header" style="text-align:right"><i>Activation Recon Report</i></div>
<hr/>
<?php
Table::create(array(
"dataStore" => $this->dataStore("sales"),
"cssClass" => array(
"table" => "table table-bordered"
),
));
?>
</body>
</html>
Let KoolReport help you to make great reports. It's free & open-source released under MIT license.
Download KoolReport View demo