Skip to content

sPDF setPage() does not work in case of html(), renders html source always into first page with xOffset and yOffset 0 #2290

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
VKB2612 opened this issue Feb 22, 2019 · 1 comment

Comments

@VKB2612
Copy link

VKB2612 commented Feb 22, 2019

Hi,

I need to add panel contents (Selection Criteria) to each page in PDF (header panel). I am using the new html() method to do this. I am trying to set the current page using setPage() function but the output PDF has all the header panels in first page with xOffset and yOffset 0 and hence overlapped on each other.

jsPDF v1.5.3
Please refer fiddle: https://jsfiddle.net/nzgr2a7y/3/

The header panel is coming twice but in page 1. It should be present in each page once. Also is there any way to set xOffset and yOffset to html() like in options. The options does not have these properties defined in the function definition.

As fromHTML(), addHTML() and html2pdf() are deprecated, using html() which is working fine with CSS and everything apart from this issue. Any help would be highly appreciated. Thank you.
Regards

@Uzlopak
Copy link
Collaborator

Uzlopak commented Mar 18, 2019

Duplicate of #1176

@Uzlopak Uzlopak marked this as a duplicate of #1176 Mar 18, 2019
@Uzlopak Uzlopak closed this as completed Mar 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants