PHP code example of ignited / laravel-pdf

1. Go to this page and download the library: Download ignited/laravel-pdf library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ignited / laravel-pdf example snippets


return array(
	# Uncomment for 32-bit systems
	'bin' => base_path() . '/vendor/h4cc/wkhtmltopdf-i386/bin/wkhtmltopdf-i386'

return array(
	# Uncomment for 64-bit systems
	'bin' => base_path() . '/vendor/h4cc/wkhtmltopdf-amd64/bin/wkhtmltopdf-amd64'

    'providers' => array(
        // ...
        'Ignited\Pdf\PdfServiceProvider',
    )

    'aliases' => array(
        // ...
        'PDF'			  => 'Ignited\Pdf\Facades\Pdf'
    )

Route::get('/', function() {
	$pdf = PDF::make();
	$pdf->addPage('<html><head></head><body><b>Hello World</b></body></html>');
	$pdf->send();
});
sh
php artisan config:publish ignited/laravel-pdf