jquery.PrintArea.js script: Only Chrome Will Not Print Images
Reported by
toa...@gmail.com,
Dec 29 2016
|
|||||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:50.0) Gecko/20100101 Firefox/50.0 Steps to reproduce the problem: 1. Click a link 2. 3. What is the expected behavior? Images post in Print Preview and print What went wrong? No images print or in preview. Chrome seems to be the only browser that doesn't process images. Did this work before? No Chrome version: 55.0.2883.87 Channel: stable OS Version: 7 Flash Version: Browser version: 55.0.2883.87 So I'm using a script from https://plugins.jquery.com/PrintArea/ and all other browsers that I'm using it with (IE, FF, and Safari) will print images EXCEPT CHROME. This seems to be an ongoing problem with Chrome browsers. I've posted in several forums and one consistent reply was to change the setTimeout to a higher number for Chrome to process the images. This has been done and even to the point where the user would have to sit and wait forever just to see the print preview (which is not acceptable) and Chrome still will not process the image for printing. It has no problem processing the text output. I need to get this issue resolved ASAP or find me another script that Chrome will work with (which I've already tried alternatives with the same results). Anyone have suggestions?
,
Jan 4 2017
,
Jan 5 2017
toad78@ By opening the link https://plugins.jquery.com/PrintArea/ and downloading the available version from jquery, unable to see any image files which can be printed. Could you please provide a sample test case or URL of the file to test this issue from chrome-TE end. Thanks!
,
Jan 18 2017
Hi everyone, I have the same problem. To reproduce it, you only need to add a link and a div to print and make something like:
$('#printLink').click(function() {
$('#printArea').printArea();
return false;
});
If you add a sleep before the call on printArea, it works. So I'm assuming that there's a race condition somewhere.
Thanks!
,
Jan 19 2017
Anyone figure this out yet? I'm still experiencing the problem.
,
Jan 27 2017
Thank you for providing more feedback. Adding requester "brajkumar@chromium.org" for another review and adding "Needs-Review" label for tracking. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Mar 13 2017
Cleaning up "Needs-Review" label as we are not using this label for triage. Ref bug 684919
,
Mar 13 2017
,
May 1 2017
Is this still an issue in Chrome 57+? If so, does this occur only on Windows 7 and not on Windows 10? Created a test as described in comment 4 with a div to print that contained images. Tested on Windows 10 with both Chrome 55.0.2883.87 and current Stable (58.0.3029.81) and could not reproduce the issue - images appeared in print preview.
,
May 2 2017
Yes, it is. I've tested it in MacOs Sierra, Ubuntu 16 and W7. Here's what I see in ubuntu, using chrome 58 (without the sensitive info). Basically, it's empty.
I can reproduce it using a few divs with some text and a function like:
$('#printLink').click(function() {
$('#printArea').printArea();
return false;
});
Does it help? Thank you for your time!
,
May 2 2017
Cannot reproduce this on Linux either, will try to test on Mac.
I have a simple test case with a button and 2 divs. I have a function identical to the above to call printArea on one of the divs when the button is clicked:
$("#print-button").click(function() {
$("#print-div").printArea();
return false;
});
When the button is clicked the contents of the print div (both text and images) appear in the print preview and the contents of the other div do not. Is there some key difference between this test case and your case?
,
May 2 2017
Test case attached for reference. Tested on Mac and also saw the images and text appear in the preview. If this is substantially different from what you are using, could you attach a similar test case that we could use to try to reproduce this issue?
,
May 3 2017
Hey, thank you for your time, again. I've attached a small example here. And I've found something that might be useful... if you comment the stylesheet line (besides the css file is empty), it works.
,
May 3 2017
Hey, I've just realized that I've made my example so simple that it does not include images. But the same happens to me if I change the text for an image :)
,
May 3 2017
Thanks for the test case. I tested on Linux and saw the empty preview as you described. The change due to removing the CSS line is indeed odd. I also found something else - if you use a more recent version (e.g. 2.4.1) of the jquery PrintArea script, does this work for you? I noticed that the printArea script you are using is version 2.1, which says it was tested only in Firefox and IE. When I substituted it for version 2.4.1, which says it was tested in Chrome 33 as well, the preview contained the content of the print area div.
,
May 4 2017
To be completely honest, I was convinced we were using the latest version of the plugin. It always worked until version 55 of Chrome, so I guess we didn't pay attention at that point. From my side, I think the problem is solved, at least using current versions (I don't have an old one here to check). Thank you!
,
May 4 2017
No worries. Closing this for now, but happy to re-open if it is still an issue for anyone else, and please open a new issue if this comes up again in future versions of Chrome. |
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by cbiesinger@google.com
, Dec 30 2016