It is currently Tue Oct 08, 2024 9:10 am


All times are UTC


Forum rules


Please click here to view the forum rules



Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: Re: best programs to batch convert URLs or HTML files to PDF
PostPosted: Fri Jun 10, 2022 12:18 pm 
Newbie
Newbie

Joined: Mon May 30, 2022 12:28 pm
Posts: 4
You can just print to PDF from a headless copy of Chromium. The first two lines install it from npm, but you can also just use your regular copy of Chrome.

npm install chromium

CHROME_PATH="$(pwd)/node_modules/chromium omegle.2yu.co /lib/chromium/chrome-linux/chrome"

$CHROME_PATH --headless --no-sandbox --disable-gpu --disable-web-security --run-all-compositor-stages-before-draw --virtual-time-budget=5000 --font-render-hinting=none --print-to-pdf=OUTPUT.pdf https://example.com

Instead of https:// for your URL, you can also omeglz do file:/// for a local HTML file.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ]  Moderators: Moderators, Support Team

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Hosting | Domains | Servers | Extras | Order | Support | Contacts | FreeHostia © 2011