#536 Copy/Paste of links within document adds filename

0.8b1
open
nobody
7
2009-11-23
2009-11-11
Ian BK
No

Within the main WYSIWYG window, when you copy-and-paste a link to an anchor within the current document (e.g. <a href="#here">), the current file name is prepended (e.g. to become <a href= "thisfile.html#here">).
If the file is subsequently renamed outside KompoZer, the link becomes broken (as it now points outside the document, to a file that may not exist).

This has been a "feature" since at least v 0.7, and remains in 0.8b1 (on Windows at least).
I cannot see any reason why this should be the case, nor can I see a way of turning it off.
If there is a reason that some users would want this, it would be good if it could be turned on or off (presumably through Options/General).

This is easily the most annoying thing I come across with KompoZer!

Discussion

  • KompoZer version 0.8b1 (20091011) | Linux

    I can't reproduce your bug. There is a bug on paste command which doesn't keep formatting by default, so I don't have any link when pasting a copied link.

    Can you provide us more information ? Your platform ? Can you describe step-by-step how you edit your anchors, your links, how you did your paste and copy,... ? A specific to examine ?

     
    • milestone: --> 0.8b1
     
  • Ian BK
    Ian BK
    2009-11-23

    My platform is Windows XP.

    Consider an HTML document containing the following lines:

    This is an <a name="anchor"></a>anchor.<br>
    This is a <a href="#anchor">link</a> to that anchor.

    It is saved on my local machine as the file is saved as e:/temp/test.html

    I open this to edit using Kompozer.
    In the "Design" pane, select the text "This is a link to that anchor".
    Cut.
    Move insertion point (to before the "This is an anchor")
    Paste.
    File now reads

    This is a <a href="test.html#anchor">link</a> to that anchor.<br>
    This is an <a name="anchor"></a>anchor.<br>

    The inclusion of the "test.html" in front of the #anchor means the relative nature of the link is broken. If test.html is renamed (or even a "Save As...", the link becomes broken.

    The issue appears with both Kompozer 0.8b1, and the earlier 0.7.10. It appears on other machines also using Windows XP.

     
    • priority: 5 --> 7
     
  • Confirmed under winXP. This bug doesn't seem to appear on GNU/Linux.