Links get broken when editing a page.
Asked by Cruz Meza:

Hello,

We have a page with links to a share drive. There are about 200 links to different folders on our drive. We add new links to this page often.

If I try to edit the page, all the previously established links disappear.

When I visit the page all the links are still showing up. All the links show up in red and get underlined when I hover the mouse over them.

When I click on 'Edit' the links still show up as red. They still get underlined when I hover the mouse over them. If I were to click on one of the links nothing happens. Before this started happening, when I clicked on a link while editing, I would have the option to edit the link or go to the link.

If I click publish, all the links still show up as red and get underlined when I hover over them. If I click the link nothing happens. If I added new links while editing, those links are the only links that actually work.

How Can I fix this?

Using Confluence 6.0.6

Regards,

Alonso


Answers:
author: AnnWorley
body: A bug was reported and fixed for this: [Links can't be edited or clicked on after saving the page](https://jira.atlassian.com/browse/CONFSERVER-46039)

Please see this [comment](https://jira.atlassian.com/browse/CONFSERVER-46039?focusedCommentId=1551549&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-1551549) for more information about the fix versions and workarounds.

comments: author: IT Support
body: Thank you Ann!


author: AnnWorley
body: How are the links defined? I had the idea you couldn't link to a share or a local file:

[Cannot link to local files from within Confluence](https://confluence.atlassian.com/confkb/cannot-link-to-local-files-from-within-confluence-216958257.html)

Are you using a plugin for this functionality?

I can restore the storage format on a test instance and see if I get the same behavior, that will be the fastest way to explain how the page is set up.

Please create a test page with some links you don't mind sharing on the Internet, then:

1. Click on the ellipsis (...) in the top right-hand corner and select **View Storage Format** from the dropdown.??
2. Copy the storage format to a file and paste it in here as code

   ```
   ?
   ```

comments: author: Cruz Meza
body: I am adding the links in the following format.

```
file://DriveLocation/path to file
```

This is what the test page with one link looks like. I changed a couple words in the drive location.

```
<p class="auto-cursor-target"><br /></p><table><colgroup><col /><col /><col /><col /></colgroup><tbody><tr><th>sdafasdfdsa</th><th>dsfadfasdfsa</th><th>dsfasfsafsa</th><th>dsfasdfsad</th></tr><tr><td><br /></td><td><br /></td><td><br /></td><td><a href="file://something.cos.is.something.com/EUC_Gshare/tmcc">Link1</a></td></tr></tbody></table><p><br /></p>
```

Link1 is the text that is linked to the drive.

If I click on the link I get taken to that directory. This is the Storage format when I go and edit the page to add another link.

```
<p class="auto-cursor-target"><br /></p><table><colgroup><col /><col /><col /><col /></colgroup><tbody><tr><th>sdafasdfdsa</th><th>dsfadfasdfsa</th><th>dsfasfsafsa</th><th>dsfasdfsad</th></tr><tr><td><a href="file://something.cos.is.something.com/EUC_Gshare/tmcc">Link2</a></td><td><br /></td><td><br /></td><td><a>Link1</a></td></tr></tbody></table><p class="auto-cursor-target"><br /></p>
```

As you can see. Link 1 no longer has the linke. The only link that is actually linked is the new one I added, Link2.

This only started happening about 2 weeks ago.


author: AnnWorley
body: I tested on Confluence 6.0.6 and Confluence 6.1.1 (latest) and the behavior is as you report - the link looks like a link after you edit the page, but the "link" is no longer clickable and the href disappears from the storage format.

<br />

I wonder what could have made this start affecting you 2 weeks ago.


author: Greg Walker
body: I am getting the same issue using 6.1.2 and it is quite frustrating. Eveyr time I change formatting or structure on the page some or all the links are no clickable but still appear liek a hyperlink.

Some are links to a network filepath and others to SharePoint sites. Any help would be appreciated here.


author: Cruz Meza
body: I found a slight workaround. You can insert an HTML Macro. Copy the code with the links from the View-\>Storage Format to the HTML Macro.

This will keep the links when editing. The problem is that it makes it a nightmare to go back in and add more things.


author: Greg Walker
body: Ok that works to add a link but will be messy and slow to setup a lot of links. Does this stop the link being lost then when you edit the page?

N.B. I cant wokr out which edits cause this, some copy/paste actions wokr fine but adding new columns or changing headings seems to break it but I need to re-test this theory.


author: Greg Walker
body: So after much more testing I can conclude that any links I am adding to a page are being lost when either: changing heading formats or adding a column or section break.

The links I am adding are in the format of:

(network filepath)

file://///servername/fullfilepath

(SharePoint site)

document name\|http://server/fullfilepath

for some reason I could only get the network filepath to work with 5 forward slashes and changing the back slashes all to forward slashes.

The links work fine in edit mode and immediately after publication but when I go back to the page and make changes like the heading style, new columns or section breaks they are lost.

I can use the work aorund suggested but have an entire organsistion to build Confluence pages around and this is not really a good option. I would appreciate if anyone else has any ideas why these links are breaking. Is this is a code defect?


author: Trupanion IT
body: This has been happening consistently since we upgraded to Confleunce 6.1.x from Confluence 5. Seems strange that there has been no mention of this since May?


author: Cruz Meza
body: Other than the workaround, I have not found another solution to this problem.


author: IT Support
body: I have this same issue. My Confluence version is 6.2.1.

I can add a link (using Web link) that looks like this:

slack://channel?team=ASD8F9A\&id=D98GH7FD

This invokes Slack and goes to the specified Slack channel in the link. This works fine when I create the link and save the page. Then if I edit the page, whether I actually change anything or not, and save the page, it removes all the links. Like the others here have posted, it still looks like its a link after the edit, but when you click on it nothing happens. It is extremely frustrating. I hope someone has an idea about how to fix this soon.

Just so no one is confused about the name on this post, my company is using the 'IT Support' name on our account. My name is Tony.


Tags: synchrony