Writer Hyperlink Oddity

I have an odd problem with document hyperlinks in Writer, one which I never experienced when using Open Office or, before that, Word.

I have many Writer files containing hyperlinks to PDF documents on my hard drives. The problem only occurs when I create a hyperlink to a document still being added to such as "Dockets_1896-1897_08_a.pdf." The hyperlink looks fine in Writer when I create it, but when I come back to the Writer file some hours or days later the visible hyperlink has changed to "Dockets_1896-1897_08 _a .pdf" where the spaces between "08" and "_a" and between "_a" and ".pdf" are so narrow as to be almost invisible, and where"Dockets_1896-1897_08" "_a" and ".pdf" are three separate hyperlinks, all with the original destination.

After finishing the additions to the document I change the filename, destination, and hyperlink to "Dockets_1896-1897_08.pdf" (the "_a" is only there to show that the PDF is not yet complete) and never again have a problem with that hyperlink. What is puzzling is that only some of the hyperlinks with the "_a" suffix suffer from this problem - not all of them. Any ideas?

Dale H. Cook, Member, NEHGS and MA Society of Mayflower Descendants;
Plymouth Co. MA Coordinator for the USGenWeb Project
Administrator of http://plymouthcolony.net

Hello Dale,
                      I have not met this problem (yet!). If you create a
hyperlink to a pdf document, but without the 'a' unfinished indicator
I take it that the hyperlink remains unchanged regardless of the
file being accessed again. It appears to be an issue with the single
character. Perhaps if you omitted the final underbar so that the
link read 8a instead of 8_a. The 'a' could be deleted when the
document is complete, just as you are doing now.

I know that this does not tell you why this occurs, but it might cure it.
Am working with hyperlinks while editing multi-lingual translations of
a system manual and have met several unexpected issues. Yours may
be yet to come!

Gordon
Tauranga
New Zealand.

Hi :slight_smile:
Also not answering the question but this time not very helpfully either ...

I've never understood why underscores are so popular. I tend to find they
create all sorts of problems, especially in links or chapter headings. It
is very hard to see them when the whole link gets automatically underlined
on almost any system by default. When people 'have to' rewrite or re-key
the link there is often confusion about whether it's an underline,
underscore or empty-space (except that spaces tend to get changed to "%20"
making the whole thing unreadable to almost everyone). Also when using
"Ctrl and keyboard-arrows" to move through text one-word-at-a-time the
cursor jumps right over underscores as though they were part of the word.
At least they don't often get converted to some sort of coding, unlike
spaces, but normal hyphens don't seem to create any of these problems.

Luckily, for me, Gnu&Linux abounds with file-renamers making it easy for me
to batch-process entire directories/folders full of all sorts of ugliness
(such as inconsistently capitalising .jpg or file-endings, where the format
is the least important thing for me).

Usually i can ignore my pettiness about such issues, luckily!!

Btw the email process converts all letters to lower-case so people can use
capitalisation judiciously to make addresses easier for humans to read.
CamelCase tends to be easier to read than alllowercase, for example;

TomCecf@Gmail.com

or

BridgeWaterMA@PlymouthColony.net

I've just noticed that Chrome seems to convert all upper-case in web-site
addresses to lower-case too but i'm fairly sure Internet Explorer is not
sophisticated enough, unless it's been introduced fairly recently (ie
within the last 5 years or so). I'm not sure about other web-browsers.

Regards from
Tom :slight_smile:

I take it that the hyperlink remains unchanged regardless of the file being accessed again.

That is correct - I have thousands of PDF hyperlinks without _a in dozens of Writer files that never change.

It appears to be an issue with the single character.

I strongly expect that it is an issue with filenames that end in _x where "x" is an alpha character. I have a few hundred PDF filenames hyperlinked in Writer files that end in _n where "n" is a digit, and those have never been affected in Writer.

Perhaps if you omitted the final underbar so that the link read 8a instead of 8_a. The 'a' could be deleted when the document is complete, just as you are doing now.

I might try that, but the reason for the underscore is that it makes files still being modified stand out better in the Writer files and in directory listings.

I know that this does not tell you why this occurs, but it might cure it.

It is not a viable long-term cure because so many filenames and hyperlinks would have to be changed.

Dale H. Cook, Member, NEHGS and MA Society of Mayflower Descendants;
Plymouth Co. MA Coordinator for the USGenWeb Project
Administrator of http://plymouthcolony.net

That is never the case on my systems, as I do not have hyperlinks underlined in LibreOffice programs. These _a suffixed links are never used on any of my thousands of web pages where hyperlinks are underlined

Dale H. Cook, Member, NEHGS and MA Society of Mayflower Descendants;
Plymouth Co. MA Coordinator for the USGenWeb Project
Administrator of http://plymouthcolony.net

Hi :slight_smile:
Sorry for the rant! I wasn't aiming it at you personally. I guess it's
just been a long time since i've had a good rant.

Many apols and regards from
Tom :slight_smile:

​On that particular topic: ​even if almost all OS got support for spaces in
file names (some later than others...), remember that spaces are also used
as a separator in a lot of things.

Obviously, good programming and carefulness can avoid almost all issues,
but the amount of code that's either quickly written, or old, or
unmaintained, or anything, that will not handle spaces in filenames is
frightening. Shell scripts are a major contender of course, but some
"higher level" programs can also mess things, if only by passing arguments
to other programs or ignoring some FS-specific restrictions, etc.
Add to that the inconsistencies (mainly from ONE os though... cough cough)
and avoiding spaces in filenames (as well as avoiding other uncommon
characters) is a sure-fire way to avoid any issue when working with all
that.

Not later than today I found myself giving the path of a file to a program,
only to find out that that specific program will cut arguments *itself* on
the spaces, in addition to taking multiple arguments. The developer
probably never understood why he gets multiple values in argv[], but still.

​If only we could fix all the bad code out there​... :wink:

Spaces in a filename are a pain in all Unix/Linux command line actions.

This is because a space is a delimiter, unless within quotes or escaped.
In shell scripts quotes and escapes (\ ) are interpreted, so any sub script does not get them, unless specific actions are taken, e.g. un Unix use single quotes around double quotes, so that the double quotes are sent to the called script.

Anyway, spaces in a filename is really a pain..