Install wkhtmlpdf from composer

Find out the CPU infomation like i386 / i686

uname -m

Install the wkhtmlpdf from composer

Reference: KnpLabs/snappy

php composer.phar require h4cc/wkhtmltopdf-i386 0.12.x

Install the dependency libraries

apt-get install libxrender1
apt-get install libfontconfig1
apt-get install libssl1.0-dev

Install fonts

Simple way, but this font is bad (my feel)

apt-get install xfonts-wqy

Complex way, install the Noto fonts (may need to install the fontconfig)

Apt reference Install noto font

apt-get install fonts-noto-cjk

Manual reference: Install noto font

cd ~/Download

wget -c

unzip -d Noto

mv Noto /usr/local/share/fonts/

ls -la /usr/local/share/fonts/

chown -R root.staff /usr/local/share/fonts/Noto

ls -la /usr/local/share/fonts/

chmod -R 644 /usr/local/share/fonts/Noto/*
chmod 755 /usr/local/share/fonts/Noto

// apt-get install fontconfig

fc-cache -fv
fc-match -a | grep Noto
fc-match -a | grep CJK


Install the libssl1.0-dev to fix the following message
QSslSocket: cannot resolve CRYPTO_num_locks
QSslSocket: cannot resolve CRYPTO_set_id_callback
QSslSocket: cannot resolve CRYPTO_set_locking_callback

Check the HTML is or not contain localhost or cannot connect address

Exit with code 1 due to network error: ContentNotFoundError

Install the fontconfig to fix the following message

command not found: fc-cache