Forum Moderators: open

Message Too Old, No Replies

links to local files in Firefox

works in MSIE, not in FF

         

ringsoft

11:03 am on Jun 7, 2005 (gmt 0)

10+ Year Member



Hi

I'm working on an intranet page, and the client wants it to have links to internal documents, ie documents stored on their own server. I've coded the links like this -

<a href="file:\\P:\test.doc" target="_blank" title="Letter template">Letter</a>

and in MSIE, sure enough, it opens a new MS Word window and loads the document - exactly what is wanted.

In Firefox, however, this doesn't happen. Instead I get an error message whish suggests to me that FF is getting the path confused - I think it is treating the path as relative to the web page, rather than as an absolute path.

Actually, it has just occured to me - could this be because I'm testing this on a local machine, rather than on a web server?

Any thoughts welcome.

BlobFisk

11:07 am on Jun 7, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try using three forward-slashes (/) after file and using forward-slashes in general:

file:[b]///[/b]P:[b]/[/b]test.doc

This should work in all browsers.

HTH

ringsoft

11:11 am on Jun 7, 2005 (gmt 0)

10+ Year Member



Wow, not only was that response fast, it works as well!

Many thanks, much appreciated Sir.