* Mangled Hyperlinks in Reports and Websites
- tatewise
- Megastar
- Posts: 27078
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Mangled Hyperlinks in Reports and Websites
Each Repository Record offers a Website URL field, but you may enter an Internet URL in any free text field.
When using Save Report As or Create a Website any URL in a field should become a Hyperlink (except for the Text File option).
Very simple URL such as http://www.freebmd.org.uk usually work OK.
Also PDF File Reports often cope well with more complex URL.
However, three scenarios cause the Hyperlink to be mangled, especially when using Web Page (HTML) Reports and Create a Website.
URL Contains an Ampersand (&)
Any URL with an ampersand (&) character causes the Hyperlink to truncate at the & which mangles the HTML code.
Examples of such URL are:
http://www.streetmap.co.uk/map.srf?x=434059&y=386876
http://www.ukgr.dreamhosters.com/gmap.p ... -1.4894915
URL Consumes the Full-stop (.)
In the Sources section, Repository fields end with a sentence full-stop.
If the field is a URL then the full-stop follows the URL and becomes embedded in the Hyperlink.
Despite the embedded full-stop the Hyperlink often still works, but the following URL fails:
http://www.multimap.com/maps/?qs=S10+2FW
URL Splits Across End of Line
Sometimes the Hyperlink HTML code ... splits across lines and the line break appears in the Hyperlink text as a blank space.
Despite this embedded character the Hyperlink usually still works, but just looks a bit odd.
Has anyone noticed these problems, or have a workaround?
ID:4708
When using Save Report As or Create a Website any URL in a field should become a Hyperlink (except for the Text File option).
Very simple URL such as http://www.freebmd.org.uk usually work OK.
Also PDF File Reports often cope well with more complex URL.
However, three scenarios cause the Hyperlink to be mangled, especially when using Web Page (HTML) Reports and Create a Website.
URL Contains an Ampersand (&)
Any URL with an ampersand (&) character causes the Hyperlink to truncate at the & which mangles the HTML code.
Examples of such URL are:
http://www.streetmap.co.uk/map.srf?x=434059&y=386876
http://www.ukgr.dreamhosters.com/gmap.p ... -1.4894915
URL Consumes the Full-stop (.)
In the Sources section, Repository fields end with a sentence full-stop.
If the field is a URL then the full-stop follows the URL and becomes embedded in the Hyperlink.
Despite the embedded full-stop the Hyperlink often still works, but the following URL fails:
http://www.multimap.com/maps/?qs=S10+2FW
URL Splits Across End of Line
Sometimes the Hyperlink HTML code ... splits across lines and the line break appears in the Hyperlink text as a blank space.
Despite this embedded character the Hyperlink usually still works, but just looks a bit odd.
Has anyone noticed these problems, or have a workaround?
ID:4708
- PeterR
- Megastar
- Posts: 1129
- Joined: 10 Jul 2006 16:55
- Family Historian: V7
- Location: Northumberland, UK
Mangled Hyperlinks in Reports and Websites
I've just tried pasting one of the above links containing an ampersand into the Web Site for a Death event, and then saving the results of a Fact query as PDF.
I was pleasantly surprised to find that the hyperlink in the PDF looks OK:

and, more importantly, works OK.
I hope this helps.[smile]
I was pleasantly surprised to find that the hyperlink in the PDF looks OK:

and, more importantly, works OK.
I hope this helps.[smile]
- Jane
- Site Admin
- Posts: 8440
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Mangled Hyperlinks in Reports and Websites
For the ampersand problem, try replacing & with &
- tatewise
- Megastar
- Posts: 27078
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Mangled Hyperlinks in Reports and Websites
Peter, as I mentioned in my post, PDF File Reports often cope well with complex URL but try http://www.multimap.com/maps/?qs=S10+2FW and it will fail if it is followed by an end of sentence full-stop.
The main problem is with the Web Page (HTML) Report and Internet > Create a Website options.
Jane, I tried replacing & with & and it did NOT fix the problem in the Web Page (HTML) Report nor Create a Website options, and furthermore it mangled the previously working Hyperlinks in PDF File Reports !!!
Also, don't forget the Full-stop (.) and End of Line scenarios.
The main problem is with the Web Page (HTML) Report and Internet > Create a Website options.
Jane, I tried replacing & with & and it did NOT fix the problem in the Web Page (HTML) Report nor Create a Website options, and furthermore it mangled the previously working Hyperlinks in PDF File Reports !!!
Also, don't forget the Full-stop (.) and End of Line scenarios.
- Jane
- Site Admin
- Posts: 8440
- Joined: 01 Nov 2002 15:00
- Family Historian: V7
- Location: Somerset, England
- Contact:
Mangled Hyperlinks in Reports and Websites
The reason I did not mention them was I could not see a way to fix them. An alternate method for now would be to use one of the 'shortcut' generators such as tr.im, or simply to use a search and replace after generation to correct the issues.
I have passed this link over to Calico to look at.
I have passed this link over to Calico to look at.
- tatewise
- Megastar
- Posts: 27078
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Mangled Hyperlinks in Reports and Websites
The URL 'shortcut' suggestion to workaround the & is a good idea.
(Note that the tr.im service will close by the end of 2010, but there are plenty of other similar services).
Today I discovered yet another problem:
URL Contains a Hyphen (-)
If a URL contains a hyphen (-) character and does not fit within the rest of a line, then it is treated as a hyphenated word, and may get split across two lines.
Then in a PDF File Report the Hyperlink gets truncated at the hyphen at the end of the line and does not work correctly.
An example of such a URL is:
http://www.ukgr.dreamhosters.com/gmap.p ... -1.4894915
The URL 'shortcut' suggestion would also workaround this feature!
The fix that Calico should consider is to treat each URL as a special string of characters.
All normal processing such as replacing & with & in HTML and splitting hyphenated (-) words across lines must be inhibited.
Note that any URL may contain ampersand (&), hyphen (-), solidus (/), query (?), full-stop (.), and other symbols, but that a full-stop (.) never appears at the end of a URL.
Thus an end-of-sentence full-stop following a URL is never part of it.
(Note that the tr.im service will close by the end of 2010, but there are plenty of other similar services).
Today I discovered yet another problem:
URL Contains a Hyphen (-)
If a URL contains a hyphen (-) character and does not fit within the rest of a line, then it is treated as a hyphenated word, and may get split across two lines.
Then in a PDF File Report the Hyperlink gets truncated at the hyphen at the end of the line and does not work correctly.
An example of such a URL is:
http://www.ukgr.dreamhosters.com/gmap.p ... -1.4894915
The URL 'shortcut' suggestion would also workaround this feature!
The fix that Calico should consider is to treat each URL as a special string of characters.
All normal processing such as replacing & with & in HTML and splitting hyphenated (-) words across lines must be inhibited.
Note that any URL may contain ampersand (&), hyphen (-), solidus (/), query (?), full-stop (.), and other symbols, but that a full-stop (.) never appears at the end of a URL.
Thus an end-of-sentence full-stop following a URL is never part of it.
- jeemo
- Famous
- Posts: 129
- Joined: 04 Jun 2004 07:52
- Family Historian: V5
- Location: Central Coast, NSW, Australia
- Contact:
Mangled Hyperlinks in Reports and Websites
This problem has been raised before over the last few years. (No time to look for the threads)
Here's hoping that it finally gets fixed in the next update now that Jane has referred it to Calico.
Here's hoping that it finally gets fixed in the next update now that Jane has referred it to Calico.
- tatewise
- Megastar
- Posts: 27078
- Joined: 25 May 2010 11:00
- Family Historian: V7
- Location: Torbay, Devon, UK
- Contact:
Mangled Hyperlinks in Reports and Websites
Further recent work has yielded the following extra details.
It appears that the URL Splits Across End of Line problem is caused by an 80 character limitation.
If the Hyperlink exceeds 80 characters, then a new-line is inserted every 80[sup]th[/sup] character.
This can even occur in the middle of a tag such as with disruptive effect!
Jane's earlier suggestion to use search & replace post editing is feasible, but the number of scenarios that need correcting is growing.
Post editing is also not assisted by the HTML produced by FH using a very untidy HTML layout.
HTML tidying software sometimes makes matters worse when faced with such things as disrupted tags.
Hopefully Calico can implement these relatively minor bug fixes at the next release.
It appears that the URL Splits Across End of Line problem is caused by an 80 character limitation.
If the Hyperlink exceeds 80 characters, then a new-line is inserted every 80[sup]th[/sup] character.
This can even occur in the middle of a tag such as with disruptive effect!
Jane's earlier suggestion to use search & replace post editing is feasible, but the number of scenarios that need correcting is growing.
Post editing is also not assisted by the HTML produced by FH using a very untidy HTML layout.
HTML tidying software sometimes makes matters worse when faced with such things as disrupted tags.
Hopefully Calico can implement these relatively minor bug fixes at the next release.