[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Bug: HTML Export doesn't handle internal link with spaces [8.0.7
From: |
Nicolas Goaziou |
Subject: |
Re: [O] Bug: HTML Export doesn't handle internal link with spaces [8.0.7 (8.0.7-6-g13cb28-elpa @ /home/jbalint/.emacs.d/elpa/org-20130812/)] |
Date: |
Fri, 20 Dec 2013 22:47:52 +0100 |
Hello,
Jess Balint <address@hidden> writes:
> I've generated a link to a headline with `org-store-link' and
> `org-insert-link'. It's rendered into the Org file like so:
>
> [[*Headline%20with%Spaces][Headline with Spaces]]
>
[...]
> The problem is in `org-export-resolve-fuzzy-link' which get's the path
> directly from the link:
>
> (let* ((raw-path (org-element-property :path link))
>
> But at this point it has "%20" in it which causes a problem when
> splitting it:
>
> ;; Split PATH at white spaces so matches are space
> ;; insensitive.
> (path (org-split-string
> (if match-title-p (substring raw-path 1) raw-path)))
>
Thank you for the report.
This bug exists because `org-insert-link' blindly url-hexifies links,
but nothing will unhexify it before it reaches an export back-end.
This is difficult to solve, because if you unhexify it, the very same
bug will occur on the other side (i.e. links you paste without using
`org-insert-link', which you don't want to unhexify).
IMO, `org-insert-link' shouldn't hexify links in all situations (if at
all).
Anyway, I can't think of any satisfactory solution at the moment.
Regards,
--
Nicolas Goaziou