为提升您的使用体验,本站正在维护,部分功能暂时无法使用。如果本站文章无法解决您的问题,您想要向社区提问的话,请到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 提问,我们的支持社区将会很快回复您的疑问。

搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

Thanks For Your Support in advance i want to know that when I open a website that time view print option and when I click close button then page also new window page also close. I want to copy it how i can stop this print option?

more options

WHEN I OPEN A URL THAT TIME WITH PAGE OPEN SHOWS PRINT OPTION AND WHEN I CLICK CLOSE BUTTON OF PRINT OPTION THAT TIME NEW WINDOW BUTTON IS CLOSED. I WANT TO CLOSE ONLY PRINT OPTION. PLEASE HELP ME...............THANKS

WHEN I OPEN A URL THAT TIME WITH PAGE OPEN SHOWS PRINT OPTION AND WHEN I CLICK CLOSE BUTTON OF PRINT OPTION THAT TIME NEW WINDOW BUTTON IS CLOSED. I WANT TO CLOSE ONLY PRINT OPTION. PLEASE HELP ME...............THANKS

所有回复 (1)

more options

Many sites which offer specific "print formatted" pages do that: they assume that once you have finished with the print dialog you no longer want the page itself. So for your convenience they close it. Not so convenient for you, since you still want to view the page.

I'm not aware of an easy solution for this. I can think of a couple different approaches.

First, maybe there's an add-on to solve this? That would be easiest.

Second, maybe there's a userscript to solve this?

The Greasemonkey add-on runs userscripts which you can copy or download. Be careful to install only long-establish and trusted scripts. (Is there a site that has this bad behavior that I can view without logging in? I will test one of my existing scripts to see whether it helps.)

Third, Firefox has an old system for restricting site permissions in a custom text file in your profile folder (named user.js). Editing this file is a bit advanced, and I haven't been able to test it, but the system works along these lines:


// Define a policy name for window.close permission // (assumes you don't have this pref already) user_pref("capability.policy.policynames", "nowindowclose"); // Define policy: disable sites from using window.close // in their scripts user_pref("capability.policy.nowindowclose.Window.close", "noAccess"); // List of sites subject to this policy user_pref("capability.policy.nowindowclose.sites", "firstbadsite.com secondbadsite.com");

Again, I haven't tested that and recommend looking into add-ons first.

由jscher2000 - Support Volunteer于修改