composer require ctbuh\wkhtmltopdf-api-php-client
convert($bytes, $options = array())
inline($bytes, $options = array(), $filename = 'document.pdf')
download($bytes, $options = array(), $filename = 'document.pdf')
https://wkhtmltopdf.api.ctbuh.org/
use ctbuh\PdfApi\PdfApi;
$pdf = new Pdf();
$pdf->inline("<h1>hello world</h1>");
// script stops
$html = view('admin.membership-certificates.document', $data)->render();
$pdf = new PdfApi();
$pdf->inline($html, [
'orientation' => 'Landscape',
'page-size' => 'letter',
'no-outline' => true
]);
wget https://github.com/coherentgraphics/cpdf-binaries/raw/master/Linux-Intel-64bit/cpdf
chmod +x cpdf
sudo cp cpdf /usr/local/bin/