I'm using Laravel Snappy to print POST data to PDF.
When I try to print PDF, it shows a strange preview like this.
How can I solve this?
Here is my history.
composer require barryvdh/laravel-snappy
composer require h4cc/wkhtmltopdf-amd64
composer require h4cc/wkhtmltoimage-amd64
php artisan vendor:publish --provider="Barryvdh\Snappy\ServiceProvider"
yum install wkhtmltopdf
<?php
namespace App\Http\Controllers\Tests;
use Illuminate\Http\Request;
use App\Http\Requests;
use App\Http\Controllers\Controller;
Controller
class TestsController extends Controller
{
public function download()
{
$pdf = \PDF::loadHTML('test');
$pdf -> setOption('encoding', 'utf-8');
return $pdf->inline();
}
}
I solved this. I have not been install any fonts yet my develop environments.
Here is my solved history.
yum install ipa-gothic-fonts ipa-mincho-fonts ipa-pgothic-fonts ipa-pmincho-fonts