Nginx-Rezepte: Konvertieren von HTML und URLs in PDF und PS

Um die Konvertierung von HTML und URL in PDF und PS vorzubereiten, benötigen wir nginx selbst, den htmldoc- Generator und das Plugin ngx_http_htmldoc_module . (Ich habe Links zu meinen Gabeln angegeben, da ich einige Änderungen vorgenommen habe, die noch nicht im ursprünglichen Repository gespeichert wurden. Sie können auch das vorgefertigte Image verwenden .)

Konvertieren von HTML und URL in PDF und PS
location =/file2pdf { file2pdf "file.html"; } #  FILE  PDF location =/file2ps { file2ps "file.html"; } #  FILE  PS location =/file2pdf { file2pdf "file1.html" "file2.html"; } #   FILE  PDF location =/file2ps { file2ps "file1.html" "file2.html"; } #   FILE  PS location =/html2pdf { html2pdf ", !"; } #  HTML  PDF location =/html2ps { html2ps ", !"; } #  HTML  PS location =/html2pdf { html2pdf ", !" " , !"; } #   HTML  PDF location =/html2ps { html2ps ", !" " , !"; } #   HTML  PS location =/url2pdf { url2pdf "https://google.com"; } #  URL  PDF location =/url2ps { url2ps "https://google.com"; } #  URL  PS location =/url2pdf { url2pdf "https://google.com" "https://google.ru"; } #   URL  PDF location =/url2ps { url2ps "https://google.com" "https://google.ru"; } #   URL  PS 

Source: https://habr.com/ru/post/de458982/


All Articles