printThis icon indicating copy to clipboard operation
printThis copied to clipboard

Print only First Page on Firefox browser

Open mujtaba1016 opened this issue 4 years ago • 6 comments

Describe the bug When i set the property copyTagClasses: true then it shows only First Page in Preview and also prints

To Reproduce Steps to reproduce the behavior:

$('#ID').printThis({
      copyTagClasses: true
});

mujtaba1016 avatar Oct 15 '21 19:10 mujtaba1016

@mujtaba1016 can you provide a bit more information?

  • What are you printing?
  • How many pages is it?
  • Tag classes are copied from the html and body elements, is there something in those classes interfering?
  • Have you set debug: true and inspected the print iframe to troubleshoot?

jasonday avatar Oct 15 '21 19:10 jasonday

@mujtaba1016 can you provide a bit more information?

  • What are you printing?
  • How many pages is it?
  • Tag classes are copied from the html and body elements, is there something in those classes interfering?
  • Have you set debug: true and inspected the print iframe to troubleshoot?
  • What are you printing? its a Html Form
  • How many pages is it? Total pages are 5
  • Tag classes are copied from the html and body elements, is there something in those classes interfering? Nothing. The Form is appended after ajax success and all classes are accurate in tags
  • Have you set debug: true and inspected the print iframe to troubleshoot? Yes i always set it true and remove the iframe in afterPrint hook.Because when debug false sometime my loadCSS links are not loaded properly. So that i set it to true.

I also checked one by one by setting each property to default the issues comes only when copyTagClasses is true

mujtaba1016 avatar Oct 15 '21 20:10 mujtaba1016

Did you inspect the print iframe to ensure all of the expected content is within the iframe? And that there are no formatting issues?

jasonday avatar Oct 15 '21 20:10 jasonday

Yes it contains all expected content and all Formatting is also fine

mujtaba1016 avatar Oct 15 '21 20:10 mujtaba1016

Is the content being printed in a floating or positioned container? As it says in the Wiki's Basic Troubleshooting page

Firefox has known issues cutting off content in floated containers when printing.

oculus42 avatar Oct 15 '21 20:10 oculus42

Is the content being printed in a floating or positioned container? As it says in the Wiki's Basic Troubleshooting page

Firefox has known issues cutting off content in floated containers when printing.

Its in a bootstrap modal Popup body with overflow auto. when i set copyTagClasses to false it print all pages

mujtaba1016 avatar Oct 15 '21 20:10 mujtaba1016