How can I get browsers other than IE to accept file urls?

It is not uncommon for our intranet web applications to link to publications, documents, or other resources on our shared network file servers.

In the past, we've had a bit of trouble generating links like:

file://fileserver1/folderofgoodies/rules.pdf
\\fileserver1\folderofgoodies\rules.pdf

      

The reason we didn't have any problems is because everyone in the building is using IE6 or IE7 (very few have IE8). Both URL styles worked fine in Microsoft browsers.

But if you try to click such links in other browsers, in particular Firefox, nothing happens!

On a new intranet web application I am developing, I am trying to provide cross-browser support, but any links to the local machine or local network resources seem to be ignored, at least in Firefox 3.5.3, although I admit I haven't tested other browsers yet.

Is there a way to change the way the specified files are referenced so that browsers like Firefox will accept them? I cannot do anything that requires scripts, software, extensions or any other solution to be installed on a per user / per computer basis.

I understand that suppressing said links is safe, but these links will only come from trusted local locations within the intranet, so ...

+2


source to share


4 answers


If it is an intranet, you can create a small helper server / page / webservice / whatever you link to and pass the filename as a parameter:

http://server/getlocalfile?path=file://fileserver1/folderofgoodies/rules.pdf

      



And you, by the way, will benefit from enhanced security.

+3


source


I think your only option is to reconfigure Firefox, but unfortunately you said you couldn't do that.



0


source


You can simply map the fileserver path as a virtual directory on your intranet site and link it over http.

0


source


Mozilla applications block links to local files. The only way is to install the plugin in Firefox. This link describes some of them.

0


source







All Articles