下载地址:https://wkhtmltopdf.org/downloads.html
wkhtmltopdf安装方法
1.解压wkhtmltox.tar到某个文件夹$DIR
2.设置环境变量
vim /etc/profile
在最后一行加 export PATH=$DIR/wkhtmltox/bin:$PATH 保存退出
source /etc/profile
3.运行 wkhtmltopdf 报wkhtmltopdf: error while loading shared libraries: libXrender.so.1: cannot open shared object file: No such file or directory这个错,请运行 apt-get/yum install libXrender*
运行 wkhtmltopdf 报wkhtmltopdf: error while loading shared libraries: libfontconfig.so.1: cannot open shared object file: No such file or directory这个错,请运行apt-get/yum install libfontconfig*
运行 wkhtmltopdf 报wkhtmltopdf: error while loading shared libraries: libXext.so.6: cannot open shared object file: No such file or directory这个错,请运行 apt-get/yum install libXext*
运行 wkhtmltopdf
网友评论