emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Rick Frankel <rick@rickster.com>
To: emacs-orgmode@gnu.org
Subject: Re: html5 generation minor bug
Date: Fri, 27 Dec 2013 13:10:06 -0500	[thread overview]
Message-ID: <d354be3083b23aced23629f102adf77d@mail.rickster.com> (raw)
In-Reply-To: <8738legqd2.fsf@bzg.ath.cx>

On 2013-12-27 12:23, Bastien wrote:
> Rustom Mody <rustompmody@gmail.com> writes:
> 
> When the html-doctype is set to html5 the generator still generates
> name attributes in links which is not correct html5
> http://dev.w3.org/html5/markup/a.html#a-constraints
> 
> Can you give an example of what it does and what it should do?

Rustom is referring to the fact that the `name' attribute has been
marked obsolete in HTML5.

While the html5 spec suggests using the id attribute on a surrounding
container rather than a named anchor, the id attribute is still valid
on an anchor in html5.

In fact, ox-html already has support for handling the issue:

(defcustom org-html-allow-name-attribute-in-anchors t
"When nil, do not set \"name\" attribute in anchors.
By default, anchors are formatted with both \"id\" and \"name\"
attributes, when appropriate."
:group 'org-export-html
:version "24.4"
:package-version '(Org . "8.0")
:type 'boolean)


Rustom-

For now, just set this variable to nil and the anchors will be
exported with an id and no name attribute. If `org-export-allow-BIND'
is true, putting the following in the head of the document will work:

#+BIND: org-html-allow-name-attribute-in-anchors nil

Bastien-

I will look at making this the default when i have time if the doctype
is html5 (`org-html-html5-p' is true), but it requires some work to
get the info structure passed down to `org-html--anchor'.

  reply	other threads:[~2013-12-27 18:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-27 17:20 html5 generation minor bug Rustom Mody
2013-12-27 17:23 ` Bastien
2013-12-27 18:10   ` Rick Frankel [this message]
2014-01-04 14:36     ` Bastien
2014-01-08 19:01       ` Rick Frankel
2014-01-08 23:44         ` Bastien
2013-12-28  1:50   ` Rustom Mody

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=d354be3083b23aced23629f102adf77d@mail.rickster.com \
    --to=rick@rickster.com \
    --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).