开发者

Javascript and CSS FOUC prevention interfering print stylesheet

I'm using a simple technique to prevent FOUC on my page. I have a "feedback" sliding button on my page that's initially set with display:none in my stylesheet. Later, when JS is loaded and the sliding code is loaded, i apply .css('display', 'block') with jQuery. That works perfectly.

However, when someone prints the page, my sliding button and it's content are shown in the print ver开发者_StackOverflowsion, even though i'm declaring display:none for the DIV inside the print.css. How can i fix this?


Maybe use:

display: none !important;

in your print style.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜