javascript – Print PDF from Firefox

Question:

I'm using the following command to print a PDF that is inside iFrame, and the PDF is even local, on the same server:

window.frames["imprimirpdf"].focus();
window.frames["imprimirpdf"].print();

When I send print from Google Chrome it works correctly, when I send it from Firefox it displays the following message: Error: Permission denied to access property 'print'

Does anyone know how to solve this or how to make it work in Firefox?

Answer:

Caio,

There is an old bug ( https://bugzilla.mozilla.org/show_bug.cgi?id=911444 )
in firefox's internal pdf plugin, and it hasn't been resolved as of the date of this post.

Scroll to Top