[ 
https://issues.apache.org/jira/browse/WICKET-6986?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17544776#comment-17544776
 ] 

Tilman Müller commented on WICKET-6986:
---------------------------------------

I found the root cause. One of the biggest changes in wicket 9 is de 
introduction of the CPS en COOP header support. As you can see in my 
testproject, the CPS blocking was already disabled. But the COOP header 
"Cross-Origin-Opener-Policy: same-origin" did prevent Firefox from printing. By 
setting this header to "same-origin-allow-popups" it works fine again with 
wicket 9. I don't realy understand why this change helps, but it works ;). 
Maybe somebody can explain it to me. 

> Printing of PDF's does not work in Firefox
> ------------------------------------------
>
>                 Key: WICKET-6986
>                 URL: https://issues.apache.org/jira/browse/WICKET-6986
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 9.10.0
>         Environment: Windows 10/Alma Linux
>            Reporter: Tilman Müller
>            Priority: Critical
>         Attachments: myproject-1.zip
>
>
> Since we are migrated from wicket 8.12.0 to wicket 9.9.0 we running into 
> problems with printing PDF's in FireFox. We developed a small (PDFViewer) 
> class above the WebMarkupContainer to view AND finaly print the PDF. Until 
> wicket 8 this worked/works still fine in Firefox. However we now migrated to 
> wicket 9.9.0 and viewing the PDF stil working in Firefox, but if you try to 
> push the printing button within the default pdfviewer in Firefox nothing 
> happend (except a (new) crash in the browser console). If you use the right 
> mouse click menu and using "This Frame" -> "Print Frame" printing works fine.
> I added a quickstarter project with 1 extra class "PDFViewer", Test.pdf with 
> only the word "Test" in it and a smal change in the  default HomePage.html 
> markup voor de PDF viewer. With this simple project you can easaly reproduce 
> this behaviour. So I wondering if 
> a) this is a bug sinds wicket 9 or
> b) the fault can be found in the PDFViewer class (also look at the override 
> of the renderPage method - without this override we run into another strange 
> crash). 
> With kind regards.



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

Reply via email to