can anybody tell me how to include user-style-sheet ind wkhtlmtopdf v. 0.10?
I'm refering to a local file, but that doesn't effect my Pdf anyway.
switches += "--user-style-sheet \User\...\style.css "
can anybody tell me how to include user-style-sheet ind wkhtlmtopdf v. 0.10?
I'm refering to a local file, but that doesn't effect my Pdf anyway.
switches += "--user-style-sheet \User\...\style.css "
What about using a 'real' URL syntax with your switch? Something like
switches += "--user-style-sheet file:///User/.../style.css"
wkhtmltopdf h.html h.css outpu.pdf
how to do this –
Voroshilov Another option to using the argument is to inject the stylesheet programmatically before the PDF conversion happens. Perhaps by using a URL parameter that identifies if a page is being fed to wkhtmltopdf or by downloading the page, injecting the CSS reference and then regurgitating the page for wkhtmltopdf.
In terminal
wkhtmltopdf -V
wkhtmltopdf 0.12.2.4
Command
wkhtmltopdf --user-style-sheet yourcssfile.css yourhtmlfile.html outputfile.pdf
© 2022 - 2024 — McMap. All rights reserved.
wkhtmltopdf
? One that has better support for using stylesheets? – Sporophyll