From: Lawrence Mitchell <wence@gmx.li>
To: emacs-orgmode@gnu.org
Subject: [PATCH] ox-html: Ensure space between tag and attribute when closing tags
Date: Tue, 07 May 2013 17:56:29 +0100 [thread overview]
Message-ID: <874neeybia.fsf@gmx.li> (raw)
In-Reply-To: m2ppx2ycvm.fsf@sachwertpartner.de
* lisp/ox-html.el (org-html-close-tag): Add space before attr.
We might get an attribute to a tag with no space at its start. Rather
than auditing all callers, unconditionally separate the tag from its
attributes with a space when closing the tag.
---
lisp/ox-html.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Robert Eckl wrote:
> The space between "img" and the attribute "width" is missing.
Attributes coming from the buffer didn't get a space prepended.
Here's a fix.
diff --git a/lisp/ox-html.el b/lisp/ox-html.el
index 05b99bf..0379567 100644
--- a/lisp/ox-html.el
+++ b/lisp/ox-html.el
@@ -1301,7 +1301,7 @@ CSS classes, then this prefix can be very useful."
(member dt '("html5" "xhtml5" "<!doctype html>"))))
(defun org-html-close-tag (tag attr info)
- (concat "<" tag (or attr "")
+ (concat "<" tag " " attr
(if (org-html-xhtml-p info) " />" ">")))
(defun org-html--make-attribute-string (attributes)
--
1.8.2-rc3
next prev parent reply other threads:[~2013-05-07 16:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-07 16:26 HTML-Export Images with #+ATTR_HTML: broken? Robert Eckl
2013-05-07 16:56 ` Lawrence Mitchell [this message]
2013-05-07 19:50 ` [PATCH] ox-html: Ensure space between tag and attribute when closing tags Bastien
2013-05-07 17:58 ` Lawrence Mitchell
2013-05-07 20:05 ` Bastien
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874neeybia.fsf@gmx.li \
--to=wence@gmx.li \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).