Print preview generate blank page

658 views
Skip to first unread message

Fudong Ma

unread,
Jun 8, 2017, 2:03:07 AM6/8/17
to Chromium-discuss

Our organization has a public website. I am a developer working on this issue found by users. We have print button on our website, when clicked that button, the print preview generate blank page.
This button is working fine in IE, FireFox, but not in Chrome. There are lots of people say this issue and fixes, I have tried, not working.


We have Javascript like following to print the messages when user click the 'Print' button.

function PrintElem(elem) {
    Popup($(elem).html());
}

function Popup(data) {
    var mywindow = window.open('', '', '');
    mywindow.document.write('<html><head><title>Communication</title>');
    mywindow.document.write('<link rel="stylesheet" href="/Content/NewSite.css" type="text/css" />');
    mywindow.document.write('<link rel="stylesheet" href="/Content/CandidateDashboard.css" type="text/css" />');
    mywindow.document.write('</head><body >');
    mywindow.document.write(data);
    mywindow.document.write('</body></html>');
    mywindow.document.close();
    mywindow.print();

PrintPreviewBlankPage.JPG

PhistucK

unread,
Jun 8, 2017, 2:04:10 AM6/8/17
to fudo...@gmail.com, Chromium-discuss
You can search crbug.com for an existing issue and star it. If you cannot find one, file a new issue using the "New issue" link on the same page.
Please, do not add a "+1" or "Me too" or "Confirmed" (or similar) comment. It just wastes the time of Chrome engineers and sends unnecessary e-mails to all of the people who starred the issue.

You can reply with a link to the found or created issue and might get triaged (and fixed) faster.

Thank you.



PhistucK

--
--
Chromium Discussion mailing list: chromium...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-discuss

---
You received this message because you are subscribed to the Google Groups "Chromium-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-discuss+unsubscribe@chromium.org.

Reply all
Reply to author
Forward
0 new messages