emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] Export issue of URL when the text begins with a date‏


From: David Maus
Subject: Re: [Orgmode] Export issue of URL when the text begins with a date‏
Date: Fri, 14 Jan 2011 06:44:54 +0100
User-agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (Gojō) APEL/10.8 Emacs/23.2 (i486-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO)

At Thu, 13 Jan 2011 23:00:30 +0100,
Vincent Belaïche wrote:
> 
> Hello,
> 
> I have made some invesitgation, and I found that the problem happens in
> the call of function org-export-as-html. On line 522 of this function,
> this is the following line:
> 
> (while (string-match org-bracket-link-analytic-regexp++ line start)
> 
> When the line containing the link is processed, the variable line is
> equal to the following
> 
> "[[file://localhost/c%3A/msys/1.0/temp/example.html][2011-01-01 example]]"
> 
> In that case the expression 
> 
>  (string-match org-bracket-link-analytic-regexp++ line start)
> 
> returns nil.
> 
> Now assume that I modify slightly the line so that there is not longer
> any ISO timestamp in it, like this (I just replaced the first  `-' by a
> `+', so the string is :
> 
> "[[file://localhost/c%3A/msys/1.0/temp/example.html][2011+01-01 example]]"
> 
> )
> 
> with that change the expression
> 
>  (string-match org-bracket-link-analytic-regexp++ line start)
> 
> returns 0.
> 
> My understanding is that the bug resides in this very expression.

Thanks for the investigation.  As it turned out the problem was not
with the regular expression but with the order in which different
pieces of Org mode markup were processed by `org-export-as-html'.
First the exporter processed possible timestamps, (falsely) recognized
the ISO date as part of an ISO timestamp, and replaced it with the
timestamp span.  The replacement included the square brackets what
destroyed the link markup.

I've just checked in a patch to master that changes the order of
processing links and timestamps: Now links are processed before
timestamps what fixes this problem.

Thanks for bringing this problem up again,

Best,
  -- David
-- 
OpenPGP... 0x99ADB83B5A4478E6
Jabber.... address@hidden
Email..... address@hidden

Attachment: pgpmqcldTAbWJ.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]