emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-publish skips the file name in inter-page links
@ 2010-08-18 22:44 Daniel Clemente
  0 siblings, 0 replies; only message in thread
From: Daniel Clemente @ 2010-08-18 22:44 UTC (permalink / raw)
  To: org-mode Mailinglist


Hi, here is a bug related to this syntax: <a href="#id:jgg8k741eue0">

  To reproduce this you need latest Emacs (e.g. from Bazaar), latest org-mode, and 3 files in ~/org-linktest/ (remove the BEGIN_QUOTE etc):



1) ~/org-linktest/has_ids.org:
#+BEGIN_QUOTE
*** TODO first section
	 :PROPERTIES:
	 :ID:       jgg8k741eue0
	 :END:

Something good.
#+END_QUOTE




2) ~/org-linktest/linker.org:
#+BEGIN_QUOTE
* Hi

Go to [[id:jgg8k741eue0][first section]]…

#+END_QUOTE




3) ~/org-linktest/linktest.el:
#+BEGIN_QUOTE
(add-to-list 'load-path "/w/org-mode/lisp") ; or wherever you have latest org-mode
(require 'org)
(require 'org-publish)

(setq org-publish-project-alist nil)
(add-to-list 'org-publish-project-alist 
				  `("linktest"
				   :base-directory "~/org-linktest/"
				   :publishing-directory "~/org-linktest/"
				   :auto-postamble nil
				   )
)
(setq org-publish-use-timestamps-flag nil)

; (org-publish-file "~/org-linktest/linker.org")
(org-publish-project "linktest" t)
#+END_QUOTE





To reproduce:

1) Open: emacs -Q
2) Open linktest.el
3) Eval it (eval-buffer). linker.html and has_ids.html are created in ~/org-linktest/


Result:
linker.html has this code for the link, which is wrong:

<p>
Go to <a href="#id:jgg8k741eue0">first section</a>…
</p></div>


It should be:
<p>
Go to <a href="has_ids.html#id:jgg8k741eue0">first section</a>…
</p></div>



Notes:
- It works correctly when normal export (C-c C-e H) is used.
- I tried to bisect the history tree from 5.23 to now and I saw the bug in all versions. Strange, since I thought this didn't happen before. Maybe it's in Emacs? Or it isn't a bug? But it feels like a bug.
- It also happens with new-style IDs, which are longer



Thanks,

Daniel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-08-18 22:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-08-18 22:44 org-publish skips the file name in inter-page links Daniel Clemente

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).