From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sebastian Rose Subject: Re: org-mode CSS property export bug Date: Sat, 24 Apr 2010 13:25:46 +0200 Message-ID: <87wrvxum6d.fsf@gmx.de> References: <87y6gf5g6x.fsf@gmx.de> <877hnycuqf.fsf@gmx.de> <8739ylmdkp.fsf@gmx.de> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O5dUm-0000Nq-DD for emacs-orgmode@gnu.org; Sat, 24 Apr 2010 07:26:00 -0400 Received: from [140.186.70.92] (port=41046 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O5dUk-0000NW-6s for emacs-orgmode@gnu.org; Sat, 24 Apr 2010 07:25:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O5dUi-0002QI-91 for emacs-orgmode@gnu.org; Sat, 24 Apr 2010 07:25:58 -0400 Received: from mail.gmx.net ([213.165.64.20]:52887) by eggs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1O5dUh-0002Q5-So for emacs-orgmode@gnu.org; Sat, 24 Apr 2010 07:25:56 -0400 In-Reply-To: <8739ylmdkp.fsf@gmx.de> (Sebastian Rose's message of "Sat, 24 Apr 2010 10:58:46 +0200") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Carsten Dominik Cc: emacs-orgmode@gnu.org --=-=-= Hi everyone, here's a patch for org-html.el to fix those IDs. sec-1.2 => sec-1_2 sec-1.2.3 => sec-1_2_3 --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=org-html.el_valid-CSS-IDs.patch diff --git a/lisp/org-html.el b/lisp/org-html.el index 71f62eb..133bffa 100644 --- a/lisp/org-html.el +++ b/lisp/org-html.el @@ -871,7 +871,9 @@ lang=\"%s\" xml:lang=\"%s\"> t t line))) (while (string-match "<\\(<\\)+\\|>\\(>\\)+" txt) (setq txt (replace-match "" t t txt))) - (setq href (format "sec-%s" snumber)) + (setq href + (replace-regexp-in-string + "\\." "_" (format "sec-%s" snumber))) (setq href (or (cdr (assoc href org-export-preferred-target-alist)) href)) (push (format @@ -2085,8 +2087,11 @@ When TITLE is nil, just close all open levels." " " title))) (unless (= head-count 1) (insert "\n\n")) (setq href (cdr (assoc (concat "sec-" snumber) org-export-preferred-target-alist))) - (setq suffix (or href snumber)) - (setq href (or href (concat "sec-" snumber))) + (setq suffix (or href + (replace-regexp-in-string "\\." "_" snumber))) + (setq href (or href + (replace-regexp-in-string + "\\." "_" (concat "sec-" snumber)))) (insert (format "\n
\n%s%s\n
\n" suffix level (if extra-class (concat " " extra-class) "") level href --=-=-= Who ever uses org-info.js will have to pull the new (but backward compatible) version from http://orgmode.org/worg/code/org-info-js/org-info.js provided this or something similar gets applied. Please give the server a while to run the publishing before downloading (I guess 2 hours are enough). It's now ... $ date -u Sa 24. Apr 11:13:26 UTC 2010 Best wishes Sebastian --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --=-=-=--