search
尋找貓咪~QQ 地點 桃園市桃園區 Taoyuan , Taoyuan

[Ubuntu]wkhtmltopdf – 佛祖球球

wkhtmltopdf是一個使用Webkit跟Qt實作將網頁轉成PDF檔的套件,類似的套件很多,但wkhtmltopdf最主要的功能是可以做網頁的截圖,將網頁畫面轉成pdf檔

安裝

#安裝wkhtmltopdf
apt-get install wkhtmltopdf
#安裝X window
apt-get install xvfb
#安裝中文字型
apt-get install ttf-wqy-zenhei

操作

xvfb-run wkhtmltopdf url(file) file.pdf
#加入CSS樣式
xvfb-run wkhtmltopdf --user-style-sheet style.css url(file) file.pdf

wkhtmltopdf參數列表

Categories: Linux



熱門推薦

本文由 blogjohnsonluorg 提供 原文連結

寵物協尋 相信 終究能找到回家的路
寫了7763篇文章,獲得2次喜歡
留言回覆
回覆
精彩推薦