Issue 125731 - "Target in Document" Hyperlink doesn't work when the target header has combination of number and period
Summary: "Target in Document" Hyperlink doesn't work when the target header has combin...
Status: CONFIRMED
Alias: None
Product: Writer
Classification: Application
Component: editing (show other issues)
Version: 4.1.1
Hardware: PC Windows 7
: P3 Major (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-09 08:51 UTC by wuming
Modified: 2016-04-26 19:24 UTC (History)
6 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: 4.1.2
Developer Difficulty: ---


Attachments
Bug doc (20.00 KB, application/msword)
2014-10-09 08:51 UTC, wuming
no flags Details
Test.odt (13.99 KB, application/vnd.oasis.opendocument.text)
2014-10-10 10:03 UTC, wuming
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description wuming 2014-10-09 08:51:57 UTC
Created attachment 84048 [details]
Bug doc

Simply I have added a hyperlink that specify "Target in document", but if I ctrl+click the hyperlink, it doesn't jump to the target. 

See the attachment doc file. In section "2. Title02", there is a hyperlink, it points to "1. Title 01" heading. When ctrl+clicked, it should jump to "1. Title 01" text, but it doesn't jump at all.
Comment 1 sgromack 2014-10-09 22:28:00 UTC
The attachment is a MS Word document and the hyperlink is working for me.  Can you please attach an OpenOffice document?

Also, what steps did you use to create the hyperlink?  Which "Target in document" did you use?  

I created a Cross Reference for Title 1 and 2 instead of a hyperlink and that linked good.
Comment 2 wuming 2014-10-10 10:03:23 UTC
Created attachment 84054 [details]
Test.odt
Comment 3 wuming 2014-10-10 10:12:11 UTC
I saved the doc file as ODT file (I have put it in attachment), the hyperlink still doesn't work.

The steps of creating the hyperlink:
1. Select text to be made as hyperlink.
2. Click menu "Insert" -> "Hyperlink"
3. In Left panel of the pop-up dialog, click "Document"
4. At right panel, click the target icon button at right of "Target" textfield.
5. At "Target in document" pop-up, expand "Headings" and choose "1.1. Title 01".
6. Click Apply button and close it.
7. Back to main pop-up dialog, click Apply button and then click close button.
Comment 4 Christopher Furseth 2014-10-12 01:20:17 UTC
OS: WIN 8.1
OO Version: 4.1.1

CONFIRMED - REPEATABLE

TEST 1: REPLICATED
Copy users headers from attachment given and linked header, "1. Title 01" with text using above steps
RESULT: 
Link Broken, jumped to hyperlink text instead of expected header

TEST2: REPLICATED
Copy users headers from attachment given and linked header "1. Title 01" with text then: 
Menu -> View -> Navigator -> Expand Headings -> Drag and drop "1. Title 01"
Result: 
Link Broken, jumped to hyperlink text instead of expected header

TEST3: REPLICATED
Created header "8. Test" and added text to second page then: 
Menu -> View -> Navigator -> Expand Headings -> Drag and drop "2. Test"
Result:
Link Broken, jumped to hyperlink text instead of expected header

TEST4: UNREPLICATED
Created header "a. Title" and added text to second page then: 
Menu -> View -> Navigator -> Expand Headings -> Drag and drop "2. Test"
Result:
Link Worked

OBSERVED REASON:
Unable to link a header which begins with number proceeded by a "."
Comment 5 mefinney 2014-10-13 05:54:57 UTC
Operating System: OSX 10.9.2
Open Office Version: 4.1.1

Replicated (Test 1):

1. Highlight newly typed text and click hyperlink icon
2. Click “Document” on left vertical bar
3. Select “Target” icon adjacent to textfield
4. Expand “Headings” in pop-up window and select a 1.1 Title
5. Click “apply” → “close”
6. In main pop-up, click “apply” → “close”
7. Hover over link holding apple command → click
Link broken, jumps to itself


Replicated (Test 2):

1. Select “View” from task bar
2. Click “Navigator”
3. Expand “Headings”
4. Drag “1. Title 01” link onto document
5. Click link while holding apple comment
Link broken, jumps to itself

Able to replicate bug on OSX 10.9.2, OO 4.1.1.

Error Importance: User unable to create links in a document. For a larger document, the ability to jump areas with precision is difficult.
Comment 6 sgromack 2014-10-13 13:26:05 UTC
Was able to replicate original issue using Windows XP, OO version 4.0.1.  

Created a new text document for the following steps.

Test 1:
1.	Copied user headings from attachment and added hyperlink on “2. Title02” over to “1. Title 01” as outlined in user steps
2.	When CTRL+click (or right click), hyperlink did not move and did not link to “1. Title 01” heading
Test 2:
1.	Removed the spaces from the first title and added hyperlink on “2. Title02” over to “1.Title01” as outlined in user steps.
2.	When CTRL+click (or right click), hyperlink did not move to “1.Title01” heading
Test 3:
•	Tried test #1 from Navigator mode and it did not move.
Test 4: 
•	Tried from “Styles and Formatting” and it did not move.
Test 5:
1.	Changed to letter “a” and added hyperlink on “2. Title02” over to “a. Title 01” as outlined in user steps.
2.	When CTRL+click (or right click), hyperlink moved to “a. Title 01” heading.
Test 6:
1.	Changed to special character “*” and added hyperlink on “2. Title02” over to “*. Title 01” as outlined in user steps.
2.	When CTRL+click (or right click), hyperlink moved to “*. Title 01” heading.
Test 7:
1.	Created a “frame” on the document.
2.	Instead of a “Target in Document” for “Headings”, tried a “Frame”.
3.	When CTRL+click (or right click), hyperlink moved to frame.
Test 8:
1.	Created a “table” on the document.
2.	Instead of a “Target in Document” for “Headings”, tried a “Table”.
3.	When CTRL+click (or right click), hyperlink moved to the table.
Test 9:
1.	Removed the “.” from the first title and added hyperlink on “2. Title02” over to “1 Title 01” as outlined in user steps.
2.	When CTRL+click (or right click), hyperlink moved to “1 Title 01” heading
Test 10:
•	Changed heading to “1 – Title 01”, then from Navigator mode and it did move.

Observations:  The hyperlink does not work when a combination of a number and a period is used. Using just a number works.  Using a period with another character (other than a number) works.

Also, cross reference will work as an option to link over to the “1. Title 01”.
Comment 7 Haoge Lin 2015-09-22 14:48:49 UTC
OS: Windows 10 Home
OO Version: 4.1.1

The writer separate his comments into two parts. The first part describes the bug generally and the second part is the steps to replicate the bug.
I failed to expand “Headings” in “Target in document” menu at the first. Because the writer didn’t include the step that set the title as heading style, which makes it has nothing to expand. Then I looked back to the bug description, finding he did mention the title was a header. But in this way to structure his comments, it is really easy for the readers ignore the styling detail to replicate the bug.
After I set the title as a header, I successfully replicated the bug following the steps that the writer created.

Tests:
Test 1 – Replicated
1.Create header “1. Title 01” on the first line.
2.Press Enter for several times, jump to the next few lines.
3.Type “hyperlink” and link the word to “1. Title 01” using the same way the writer did.
4.Click the hyperlink.
Result: Link Broken, jumped to the “hyperlink” text itself.

Test 2 – Unreplicated
1.Create header “1 Title 01” on the first line.
2.Press Enter for several times, jump to the next few lines.
3.Type “hyperlink” and link the word to “1 Title 01” using the same way the writer did.
4.Click the hyperlink.
Result: Link works.

Test 3 – Unreplicated
1.Create header “1, Title 01” on the first line.
2.Press Enter for several times, jump to the next few lines.
3.Type “hyperlink” and link the word to “1, Title 01” using the same way the writer did.
4.Click the hyperlink.
Result: Link works.

Test 4 – Replicated
1.Create header “1. Title 01” on the first line.
2.Press Enter for several times, jump to the next few lines.
3.Create header “2. Title 02”.
4.Press Enter for several times, jump to the next few lines.
5.Create header “3. Title 03”.
6.Press Enter for several times, jump to the next few lines.
7.Type “hyperlink” and link the word to “2. Title 02” using the same way the writer did.
8.Click the hyperlink.
Result: Link Broken, jumped to the “hyperlink” text itself.

Test 5 – Unreplicated
1.Create header “a. Title 01” on the first line.
2.Press Enter for several times, jump to the next few lines.
3.Type “hyperlink” and link the word to “a. Title 01” using the same way the writer did.
4.Click the hyperlink.
Result: Link works.

Text 6 – Unreplicated
1.Create header “一. Title 01” on the first line.(“一” is “one“ in Chinese)
2.Press Enter for several times, jump to the next few lines.
3.Type “hyperlink” and link the word to “一. Title 01” using the same way the writer did.
4.Click the hyperlink.
Result: Link works.

Text 7 –Replicated
1.Create header “1. Title 01” on the first line.
2.Press Enter for several times, jump to the next few lines.
3.Click “Navigator” icon in the task bar
4.Expand “Heading”
5.Drag “1. Title 01” into somewhere in the editor.
6.Click the hyperlink.
Result: Link Broken, jumped to the “hyperlink” text itself.

Text 8 –Replicated
1.Create a table
2.Insert header “1. Title 01” in one cell of the table.
3.Press Enter for several times, jump to the next few lines.
4.Type “hyperlink” and link the word to “1. Title 01” using the same way the writer did.
5.Click the hyperlink.
Result: Link Broken, jumped to the “hyperlink” text itself.

Text 9 –Unreplicated
1.Create header “1- Title 01” with heading 3 on the first line.
2.Press Enter for several times, jump to the next few lines.
3.Type “hyperlink” and link the word to “1- Title 01” using the same way the writer did.
4.Click the hyperlink.
Result: Link works.

Observed Reason:
Unable to link a header which begins with a number proceeded by a "."

Explanation:
I tried a lot of ways to replicate the bug, including change the symbol postfixes to the number, change the number with English letters, Chinese character, change the way to create the hyperlink, change the position of the header, etc. All those results meet the observed reason mentioned above.
For further test, I also tested the same problem in MS Word 2013. It turns out that MS Word 2013 doesn’t have this bug.
Comment 8 Devin Martinez 2016-02-17 03:54:07 UTC
Firstly, I tried replicating the bug on two different operating systems (Windows 10 Home and OS X 10.11 (El Capitan)). I attempted the same tests using the two different operating systems.

Create four pages in the test document, each with their own title at the top of the page:
page 1: 1. Title 01
page 2: 1 Title 02
page 3: 2. Title 03
page 4: 1, Title 04
page 5: a. Title 05

OS: Windows 10 Home
OO Version: 4.1.2


TEST 1 (for title 02): Not Replicated 
1.Put cursor at the end of title 01 
2.Press Enter a few times
3.Type “hyperlink for title 02” and link the word "hyperlink" to “1 Title 02” using the same method as the original poster.
4.Click the hyperlink.
Result: Link works.

TEST 2 (for title 01): Replicated
1.Put cursor at the end of title 02 
2.Press Enter a few times.
3.Type “hyperlink for title 01” and link the word "hyperlink" to “1. Title 01” using the same method as the original poster.
4.Click the hyperlink.
Result: Link does not work.

TEST 3 (for title 03): Replicated
1.Put cursor at the end of previous line with hyperlink
2.Press Enter a few times.
3.Type “hyperlink for title 03” and link the word "hyperlink" to “2. Title 03” using the same method as the original poster.
4.Click the hyperlink.
Result: Link does not work.

TEST 4 (for title 04): Not Replicated
1.Put cursor at the end of previous line with hyperlink
2.Press Enter a few times.
3.Type “hyperlink for title 04” and link the word "hyperlink" to “1, Title 04” using the same method as the original poster.
4.Click the hyperlink.
Result: Link works.

TEST 5 (for title 05): Not Replicated
1.Put cursor at the end of previous line with hyperlink
2.Press Enter a few times.
3.Type “hyperlink for title 05” and link the word "hyperlink" to “a. Title 05” using the same method as the original poster.
4.Click the hyperlink.
Result: Link works.



OS: OS X 10.11 (El Capitan)
OO Version: 4.1.2

TEST 1 (for title 02): Not Replicated 
1.Put cursor at the end of title 01 
2.Press Enter a few times
3.Type “hyperlink for title 02” and link the word "hyperlink" to “1 Title 02” using the same method as the original poster.
4.Click the hyperlink.
Result: Link works.

TEST 2 (for title 01): Replicated
1.Put cursor at the end of title 02 
2.Press Enter a few times.
3.Type “hyperlink for title 01” and link the word "hyperlink" to “1. Title 01” using the same method as the original poster.
4.Click the hyperlink.
Result: Link does not work.

TEST 3 (for title 03): Replicated
1.Put cursor at the end of previous line with hyperlink
2.Press Enter a few times.
3.Type “hyperlink for title 03” and link the word "hyperlink" to “2. Title 03” using the same method as the original poster.
4.Click the hyperlink.
Result: Link does not work.

TEST 4 (for title 04): Not Replicated
1.Put cursor at the end of previous line with hyperlink
2.Press Enter a few times.
3.Type “hyperlink for title 04” and link the word "hyperlink" to “1, Title 04” using the same method as the original poster.
4.Click the hyperlink.
Result: Link works.

TEST 5 (for title 05): Not Replicated
1.Put cursor at the end of previous line with hyperlink
2.Press Enter a few times.
3.Type “hyperlink for title 05” and link the word "hyperlink" to “a. Title 05” using the same method as the original poster.
4.Click the hyperlink.
Result: Link works.



Observation: In both operating systems, the bug was replicated the same way. The program seems to be unable to link a header which begins with a number proceeded by a "."
Comment 9 Theodore Matula 2016-04-26 19:24:19 UTC
I'm moving this to confirmed, as multiple people were able to reproduce this bug.