Opening files using plugins: Difference between revisions

From MozillaZine Knowledge Base
Jump to navigationJump to search
m (→‎Problematic browser preferences: opening, not running)
mNo edit summary
Line 1: Line 1:
A browser often requires a [[:Category:Plugins | plugin]] for media and other files that it cannot handle internally, such as [[Flash]] movies or audio content.  Such files are often embedded in Web pages, and they will run automatically via the plugin when such pages are visited. (Note that [[JavaScript]] is often required for the plugin to run correctly.)  It is also possible to invoke the associated plugin to automatically open a file by clicking on a direct download link (for example, a link to a <tt>.swf</tt> or <tt>.mp3 file</tt>), by opening a bookmark to the file, or by using the browser to open a file stored locally on your computer.  This article describes problems that may occur when attempting to open a downloaded or "directly-visited" file in Mozilla browsers using the associated plugin, and provides possible solutions.
A browser often requires a [[:Category:Plugins | plugin]] for media and other files that it cannot handle internally, such as [[Flash]] movies or audio content.  Such files are often embedded in Web pages, and they will run automatically via the plugin when such pages are visited. (Note that [[JavaScript]] is often required for the plugin to run correctly.)  It is also possible to invoke the associated plugin to automatically open a file by clicking on a direct download link (for example, a link to a <tt>.swf</tt> or <tt>.mp3</tt> file), by opening a bookmark to the file, or by using the browser to open a file stored locally on your computer.  This article describes problems that may occur when attempting to open a downloaded or "directly-visited" file in Mozilla browsers using the associated plugin, and provides possible solutions.


==Firefox Download Actions==
==Firefox Download Actions==

Revision as of 09:10, 13 July 2006

A browser often requires a plugin for media and other files that it cannot handle internally, such as Flash movies or audio content. Such files are often embedded in Web pages, and they will run automatically via the plugin when such pages are visited. (Note that JavaScript is often required for the plugin to run correctly.) It is also possible to invoke the associated plugin to automatically open a file by clicking on a direct download link (for example, a link to a .swf or .mp3 file), by opening a bookmark to the file, or by using the browser to open a file stored locally on your computer. This article describes problems that may occur when attempting to open a downloaded or "directly-visited" file in Mozilla browsers using the associated plugin, and provides possible solutions.

Firefox Download Actions

The default action for file types for which a plugin is installed is to open the directly-visited file with the plugin. Firefox allows you to change the specified download action for different types of files so that the file is opened with a selected external application or saved to disk instead. If Firefox is not treating files of a certain type in the way you want, view the list of Download Actions (under "Tools -> Options -> Downloads") and change the action as needed. Note that certain file extensions may include multiple entries, one for each MIME type associated with an installed plugin or specified download action. You can see the list of installed browser plugins and related MIME types by entering about:plugins in the address bar. Occasionally, entries may disappear from the list after changing the download action. If closing and reopening the Download Actions window or restarting Firefox doesn't restore the missing entry, try resetting the plugin-related browser preferences as described below.

Problematic browser preferences

In one reported case involving Quicktime and .mp3 file downloads, the file was being sent with the appropriate MIME type, the Quicktime plugin was enabled for that type, as shown in the "about:plugins" list, and the Quicktime browser settings were correct. Instead of opening the file via the plugin, the Firefox "Opening" dialog box would appear, asking the user to choose between opening the file in an external application or saving it to disk. Attempting to change the Firefox "Download Actions" was unsuccessful, as one of the six MIME types associated with .MP3 files was missing from the list. The problem was fixed by resetting certain plugin-related preferences, as follows:

  1. Type about:config into the address bar.
  2. Find the preference browser.download.pluginOverrideTypes and, if it is present, right-click on it and select reset.
  3. Find the preference plugin.disable_full_page_plugin_for_types and, if it is present, right-click on it and select reset.

Note: If you perform this procedure and find that the same problem persists, or if you want to remove all previously-set Download Actions and restore the default set of actions, close the browser and then open the profile folder and delete (or rename) the file mimeTypes.rdf.

Misconfigured web server

Sometimes a misconfigured web server will send a file with an inappropriate MIME type and, instead of the file automatically opening with the browser plugin, an "Opening" dialog box will appear, asking you to either save the file or open it with a chosen external application. This may happen with .wmv (Windows Media Video) files sent as "text/plain" instead of the correct "video/x-ms-wmv" MIME type (see bug 250914, probably related to the fix for bug 220807, outlined here). A Google Groups search shows that this can also occur when downloading .swf (Shockwave Flash) flies and, most likely, other types of files for which a plugin is installed, when the inappropriate "text/plain" MIME type is sent. A similar issue can occur with the "application/octet-stream" MIME type [1]. To test whether you are experiencing this problem, you should determine whether it happens with some downloads of a particular type file but not others of the same type. If so, it is likely that the web server is misconfigured; unfortunately there is nothing you can do in such cases except to contact the website about the problem.

Advanced users can use the Live HTTP Headers to detect the MIME type being sent.

Windows Media Player plugin

The Windows Media Player plugin, when loaded from a direct link, will not appear in the page and display the file like other plugins - it will just appear as a blank page, download the whole file, and then hand it off automatically to the default media player for that file type. In other words, if WinAmp or Real Player is the default media player for .wmv (Windows Media Video) files, then direct links to those files will open in WinAmp or Real Player, even if the Windows Media Player plugin is installed and set to open those files.

Shockwave Flash

A reported issue exists in certain situations where the Macromedia Flash Player is used in conjunction with Firefox 1.5 whereby Shockwave Flash files will not run automatically using the plugin when opened directly in the browser, but instead will cause the File Download dialog box to be displayed, asking the user to choose whether to save the file or open it in a suitable application. (If this occurs, there is no way of instructing the browser to run the file directly. Contrary to advice commonly given to users experiencing this problem, the bug has nothing to do with the MIME type served with the Flash file, nor with the browser settings for Flash files.) This issue appears to affect users who had installed the Macromedia Flash Player in Firefox 1.0 and who later upgraded to Firefox 1.5 without first uninstalling this plugin. To resolve the problem, users of Firefox 1.5 should uninstall their current version of Macromedia Flash Player and then reinstall it, either manually or by invoking the plugin by visiting a Web page containing an embedded Flash file and then following the browser prompts.

See also