Skip to content
\n

In PHP:

\n
$request = new HTMLRequest($contentHtml);\n$request->setPaperSize(Request::A4);\n$request->setHeader($headerHtml);\n$request->setFooter($footerHtml);
\n

Gotenber version 6.x

\n

setMargins affects just content.html, header.html still has the margin.

\n
$request->setMargins(Request::NO_MARGINS);
\n

\"Screenshot

","upvoteCount":1,"answerCount":1,"acceptedAnswer":{"@type":"Answer","text":"

Hello @idenisovs,

\n

Could you try this solution puppeteer/puppeteer#4132 (comment)? If it works, I’ll update the documentation 😄

","upvoteCount":1,"url":"https://github.com/gotenberg/gotenberg/discussions/343#discussioncomment-1303479"}}}
Discussion options

You must be logged in to vote

Hello @idenisovs,

Could you try this solution puppeteer/puppeteer#4132 (comment)? If it works, I’ll update the documentation 😄

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@idenisovs
Comment options

@gulien
Comment options

@idenisovs
Comment options

@gulien
Comment options

@neongrau
Comment options

Answer selected by idenisovs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants