LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Firefox Can't Follow HTML Hyperlinks To Local Files - Recognize Relative Hyperlinks? (https://www.linuxquestions.org/questions/linux-newbie-8/firefox-cant-follow-html-hyperlinks-to-local-files-recognize-relative-hyperlinks-711590/)

Dave Chicago 03-14-2009 10:45 AM

Firefox Can't Follow HTML Hyperlinks To Local Files - Recognize Relative Hyperlinks?
 
I'm a Linux newbie, but some people have categorized me a "Power User" of the other operating system. So I think I get the concepts, but may also need some very basic tips (like how do I get someplace to enter commands, what's really an Applet and can I change applets or whatever without rendering something inoperative).
Hardware:
(1) Dell Inspiron Mini.
Software:
(1) Whatever came with the Dell/Ubuntu Hardy Heron;
(2) Firefox
Problem:
(1) I have notes that I wrote in html using a text editor, sometimes Windows, sometimes other devices like handhelds. It is basically a table of contents with hyperlinks to local files. They work fine in Windows or Windows mobile, and I can post them on the Internet and they work, too. But the information is confidential and I don't want it on the Internet, I want it all accessible locally.
(2) I moved the files to the Linux box, but when I click on the links, Firefox can't find them.
Any idea how to make sure "relative" links work on Linux/Firefox in an html file (filename extensions, though are *.htm)?
I'd hate to have to edit 300 links and/or rename 300 files.

JulianTosh 03-14-2009 11:39 PM

Can you give me a better description of how the files are stored and how you're trying to access them?

For instance, are all the files stored and access from a local file system on the linux box (vs accessing them remotely from a different computer).

It sounds like there's some sort of index HTML file that lists all the documents and is used to navigate the files you have stored? is that the case?

syg00 03-15-2009 12:00 AM

Also, are you using windows-style names (e.g. files\notes\one.htm) ?
Let's see the error message and a couple of lines of your links.

Dave Chicago 03-16-2009 06:21 PM

The 'how the files are stored' question kind of lead to what seems to be a solution:
I was used to Windows "Shortcuts" but it seems that a Linux Create Link is read differently. I created a link to the desktop and the linking file was looking on the desktop, not in the folder where the files were located.
All are relative links anyway, so all the files have to be in the same folder.
Also, it appears that a Linux Firefox link is case sensitive -- .htm is different from .HTM.
Thanks for the tips that lead to better understanding.

syg00 03-16-2009 06:50 PM

Quote:

Originally Posted by Dave Chicago (Post 3477622)
All are relative links anyway, so all the files have to be in the same folder.

They can be in sub-folders as well - use forward slash (/) rather than backslash (\) in the link names. That way your work will be readable everywhere - even IE will handle them o.k. I tend to create a directory on a USB key and just create a top level index.htm - that way I have everything with me, and accessible.
If you want a hand to convert the backslashes, I can provide a simple command to do that for you (on Linux).

Dave Chicago 03-17-2009 10:00 PM

No slashes
 
I typed the code myself and there are no slashes. Here's an example:
<A HREF="Management.htm#Management"><STRONG>Management</STRONG></A></P>
Maybe I'm just using unsophisticated coding, being an amateur, but those seem to work. I'd be happy to learn more and thanks for your guidance.

syg00 03-18-2009 08:07 PM

Looks like it should work to me - but my HTML skills are basic at best.
Hopefully some-one else will chime in.


All times are GMT -5. The time now is 09:29 AM.