Opening files from within Firefox

Asked by Allan

I have a bunch of linked html files which I would like to browse with Firefox.

The files are presently on an HD but the ultimate intent is that they be on a CD.

Some of the files contain links to media (pdf, mp3, wav, odt etc). I need clicking (right, double right or left as long as it's consistent) on these links to open the file. I'm finding some open in another or the same window (jpg) and others (specifically mp3) are not opening at all but are in fact downloading (from their present folder to my "normal" download folder).

"View and edit actions" is NOT populated (despite REALLY downloading from the internet regularly so I am not able to set up the dependancy there.

Any help with this much appreciated.

Allan

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu firefox Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Leandro Gómez (leogg) said :
#1

Are the media files also on your HD?

When you right-click on a media file such as a pdf document you can choose if you want to download it or open it with an application (in this case, evince is the default application, I think).

Revision history for this message
Allan (ad707) said :
#2

Yes, in fact all the files are in the same folder.

In my case at least the default application is "Document Viewer" and indeed it should allow that option, but it does not. Nor does mp3 files. The options offered are "Open link in New Window, Open link in new tab, Bookmark this link, Save this link, etc."

So the issue is what do I do to fix it?

Revision history for this message
Ralph Janke (txwikinger) said :
#3

Some applications cannot resolve a url starting with media://. Try file:///media and the restof the path as in the medial:// address and see if that works.

Revision history for this message
Leandro Gómez (leogg) said :
#4

Hi Allan!

Some media files, such as mp3, will download instead of open in their default application.

A solution to your problem, since you're going to access these local media files with Firefox, is to create a HTML page with an embedded media player.

http://www.wimpyplayer.com/products/mp3/javascript_standard_options.html

You can google around a bit and find the best solution for your problem. Let me know if this helped.

Leo

Revision history for this message
Allan (ad707) said :
#5

Alas the links are already of the form file:///media - so that's not going to do it.

Revision history for this message
Alan Pope 🍺🐧🐱 🦄 (popey) said :
#6

You probably want to use relative URLs rather than absolute ones:-

Rather than:-

file:///media/foo/bar/baz.mp3

Use:-

file://./bar/baz.mp3

(assuming bar is a folder underneath where the html is located)

Can you help with this problem?

Provide an answer of your own, or ask Allan for more information if necessary.

To post a message you must log in.