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

搜索 | 用户支持

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

详细了解

Is there a way to programmatically configure Firefox to use Adobe Reader within the Firefox Browser?

  • 9 个回答
  • 4 人有此问题
  • 1 次查看
  • 最后回复者为 freesbee98

more options

We have customers who are having difficulty saving their PDF files upon opening them from our web page because most of the time, they have "Use Adobe Reader (default)" set under Tools->Options->Applications. This causes the PDF file to be loaded into a standalone version of Adobe Reader where the Save icon is disabled.

We can suggest to our users that they change this to "Use Adobe Acrobat (in Firefox)", which will give them the desired behavior of loading the PDF in a Firefox window with the Acrobat plug-in's Save icon enabled.

However, we'd like to pro-actively change this configuration for our users via javascript if at all possible, so they don't have to go through the trouble of contacting us with the issue.

Is this possible?

We have customers who are having difficulty saving their PDF files upon opening them from our web page because most of the time, they have "Use Adobe Reader (default)" set under Tools->Options->Applications. This causes the PDF file to be loaded into a standalone version of Adobe Reader where the Save icon is disabled. We can suggest to our users that they change this to "Use Adobe Acrobat (in Firefox)", which will give them the desired behavior of loading the PDF in a Firefox window with the Acrobat plug-in's Save icon enabled. However, we'd like to pro-actively change this configuration for our users via javascript if at all possible, so they don't have to go through the trouble of contacting us with the issue. Is this possible?

所有回复 (9)

more options
more options

Thanks, but the link you shared all contains information a user must do to set this up.

What I'm looking for is a way to make a configuration change to Firefox to use the Acrobat bat plug-in within the browser via javascript. Is that possible?

more options

You can set the pdfjs.disabled pref to true on the about:config page to disable the build-in PDF viewer.

You can check the value of the plugin.disable_full_page_plugin_for_types pref on the about:config page and remove the application/pdf part if present or reset the pref to the default via the right-click context menu.

See also:

more options

'cor-el the problem is that pdf documents contain interactive data/scripts/etc sometimes. This requires them to be opened in Adobe pdf viewer. But it's the worse case to force a client to open pref pane, bla-bla... Is there any obvious way, how to specify browser to open a particular document either with pdf.js, or with Adobe plugin (without additional user's input)? Any hash parameters?.. Thank you.

more options

I have the same problem, but "the other way around". I need to configure programmatically FireFox to open PDFs in Adobe Reader by default. For other similar issues (as for example the default Start Page) we are deploying the file user.js inside the UserProfile folder. Detailed functionality of user.js file is documented here:

http://kb.mozillazine.org/User.js_file

Unfortunately adding the line

user_pref("pdfjs.disabled", true)

to that file doesn't solve the problem because then FF just doesn't open the PDF.

Doing some searching I came to the information that this kind of settings are stored in the file mimeTypes.rdf (again within the userprofile, thanks jscher2000). Trying to compare the file mimeTypes.rdf before and after changing the settings brings to a mess (not human readable I would say): 327 lines different that cannot be handled.

So my question would be: is there a way to override certain entries stored in mimeTypes.rdf in a way similar to the user.js file??

由freesbee98于修改

more options

Hi freesbee98, the preferences for how to handle "downloads" are stored in mimeTypes.rdf in the individual user profile.

more options

I think that the built-in PDF Viewer only gets triggered with a specific MIME type (application/pdf) send by the server.


Bug 845740 - The web site should be able to suggest that Firefox not to use the built-in PDF viewer

more options

Hi freesbee98, mimeTypes.rdf looks like text soup, but it's an XML-based file, so you might be able to manipulate it using VBScript and the MSXML library. However, I haven't tried that myself or searched for any existing scripts, so I don't know whether it is sufficiently well formed to edit that way...

Edit: I assumed Windows, but if that's incorrect, there may be an equivalent on other platforms.

由jscher2000 - Support Volunteer于修改

more options

Yes it's windows, but once found the strategy it wouldn't be a big deal to apply that to other platforms.

mimeTypes.rdf looks relatively well formed to be edited even manually (Autodesk xmls are much much much more messy). Unfortunately I need to automate the procedure, and the effort to invest to solve this problem programmatically is a little bit too much. The bosses are IE fans, and they would immediately say "nuke FF, we can use IE".

This pdfjs was a real boomerang for Mozilla, even if I know how to change the behavior from GUI...

由freesbee98于修改