First row of table overlapping with row headers in PDF document

1,597 views
Skip to first unread message

Keenmeng Lew

unread,
Sep 2, 2016, 1:19:26 AM9/2/16
to wkhtmltopdf General

Hello,


The PDF I have generated has corrupted lines at the top - the first entry is printed over the column titles. Please see sample below for reference: -


Screen Shot 2016 08 22 at 14.28.31.png2082x79 44.7 KB


Any ideas how to fix this?


Cheers!

km

Qasim Lodhi

unread,
Sep 7, 2016, 12:57:54 PM9/7/16
to wkhtmltopdf General
Can you share a sample HTML/CSS and command for it?

Qasim Lodhi

unread,
Sep 8, 2016, 12:50:15 PM9/8/16
to wkhtmltopdf General
Can you also share the wkhtmltopdf command you are using. From your PDF looks like you are using a header on each page...?

The problem is that header is printed in a specific position on each page but the data gets printed on top of it. I haven't worked with header in wkhtmltopdf and can't till you share the command, but seems like you need to adjust margins or something for the data rows so that they don't overlap with the "static" header.

Keenmeng Lew

unread,
Sep 9, 2016, 3:15:52 AM9/9/16
to wkhtmltop...@googlegroups.com
Qasim,

The PDFs were generated from within an application called Odoo.  I’m afraid I have little idea what the exact command is but I can try to find out.

Cheers!
km

On Sep 9, 2016, at 00:50, Qasim Lodhi <qasim...@simco.com> wrote:

Can you also share the wkhtmltopdf command you are using. From your PDF looks like you are using a header on each page...?

The problem is that header is printed in a specific position on each page but the data gets printed on top of it. I haven't worked with header in wkhtmltopdf and can't till you share the command, but seems like you need to adjust margins or something for the data rows so that they don't overlap with the "static" header.

--
===================================================
You received this message because you are subscribed to the "wkhtmltopdf General" group.
To post to this group, send email to wkhtmltop...@googlegroups.com
To unsubscribe from this group, send email to wkhtmltopdf-gen...@googlegroups.com
 
For more options, visit this group at
http://groups.google.com/group/wkhtmltopdf-general?hl=en?hl=en
---
You received this message because you are subscribed to a topic in the Google Groups "wkhtmltopdf General" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/wkhtmltopdf-general/OJ2MkJGfaU4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to wkhtmltopdf-gen...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

John Russell

unread,
Feb 7, 2017, 9:57:12 AM2/7/17
to wkhtmltopdf General
I have just come across the same problem. 

I'm running the wkhtmltox-0.12.4_linux-generic-amd64.tar.xz version from Ubuntu 16.10 x64. 

The commands
wkhtmltopdf input.html output.pdf
wkhtmltopdf
--print-media-type -s A4  input.html output.pdf
both result in occasional white headers overlapping the top line of text; or print being split across the middle of the text, as well as the occasional overlapping of the top line, in a table. 

This happens a few times on a 95 page document. 

As wkhtmltopdf didn't appear to respect page-break settings in the html document I fixed it by editing the html to add blank line spacing:
<br/>

It appears to be a layout problem at the top of the page. 

Best

John
Reply all
Reply to author
Forward
0 new messages