I have a css file and I defined all rules for screen and print (with `@media print`).
Here is some code:
/* more css rules above */
@media print
{
body * {
visibility:hidden;
}
#preview, #preview * {
visibility:visible;
}
}
In IE and Firefox all work great but in chrome and chromium I get an empty page (nothing is printed) Do these browsers need any special cosiderations?
**EDIT:**
I downloaded [this plugin][1] for Chrome and Chromium that allow me debug the print stylesheet and to my surprise, the plugin show me exactly the same as Firefox and IE.
[1]: http://chrispederick.com/work/web-developer/installed/chrome/04/ Of course you will get an empty page because you are hiding everything in the body (e.g the whole page)
以上就是Empty output printed in Chrome and chromium的详细内容,更多请关注web前端其它相关文章!