emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: William Crandall <bc3141592@gmail.com>
To: Nicolas Goaziou <n.goaziou@gmail.com>
Cc: emacs-orgmode@gnu.org, Jambunathan K <kjambunathan@gmail.com>
Subject: Re: org-e-html: Including ATTR_HTML: title="hover text"
Date: Thu, 7 Jun 2012 15:26:29 -0700	[thread overview]
Message-ID: <CAENLK5ViNxSgpYu_aJsh8JO57OoFr_rxm54B7LpQ=Em413G4Hw@mail.gmail.com> (raw)
In-Reply-To: <87aa0egbvy.fsf@gmail.com>

Hello Nicolas,

Thanks for your email. You write:

"ATTR_HTML is only for paragraphs, not links."

This puzzles me, because (1) the old exporter works fine
on links that are inside paragraphs, as my example showed,
and (2) the Manual says ATTR_HTML lines are for links:

12.5.4 Links in HTML export
http://orgmode.org/org.html#Links-in-HTML-export

If you want to specify attributes for links, you can do so using a
special #+ATTR_HTML line to define attributes that will be added to
the <a> or <img> tags. Here is an example that sets title and style
attributes for a link:

     #+ATTR_HTML: title="The Org mode homepage" style="color:red;"
     [[http://orgmode.org]]


Thanks for looking at this again!

-BC


On Thu, Jun 7, 2012 at 12:28 PM, Nicolas Goaziou <n.goaziou@gmail.com> wrote:
> Hello,
>
> William Crandall <bc3141592@gmail.com> writes:
>
>> If org-mode source text is:
>>
>> --------------------------------------------------
>> A paragraph about
>> #+ATTR_HTML: title="Link hover text"
>> [[http://orgmode.org]]
>> exalting new emacs mode...
>> --------------------------------------------------
>
>> "M-x org-export-dispatch h" generates:
>>
>> --------------------------------------------------
>> <p>
>> A paragraph about
>> </p>
>> <p>
>> <a href="http://orgmode.org">http://orgmode.org</a>
>> exalting new emacs mode&hellip;
>> </p>
>> --------------------------------------------------
>>
>> which is less grand.
>>
>> I see two needed fixes, reading
>> http://orgmode.org/org.html#Links-in-HTML-export
>>
>> 1. A new </p><p> should not be inserted before
>>    lines starting #+ATTR_HTML.
>
> It sure should: you're starting a new paragraph containing a link and
> "exalting new emacs mode..." text.
>
> ATTR_HTML is an attribute for paragraphs, not links (though it may apply
> on links within the paragraph).
>
> You may want to add your title attribute with filters.
>
>
> Regards,
>
> --
> Nicolas Goaziou

  reply	other threads:[~2012-06-07 22:26 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-07  2:08 org-e-html: Including ATTR_HTML: title="hover text" William Crandall
2012-06-07  2:59 ` William Crandall
2012-06-07 19:28 ` Nicolas Goaziou
2012-06-07 22:26   ` William Crandall [this message]
2012-06-08 13:28     ` Nicolas Goaziou
2012-06-08 17:03       ` William Crandall
2012-06-08 22:37         ` Nicolas Goaziou
2012-06-08 23:53           ` William Crandall
2012-06-09 13:54             ` Nicolas Goaziou
2012-06-10  1:43               ` William Crandall
2012-06-14  9:51                 ` Nicolas Goaziou

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='CAENLK5ViNxSgpYu_aJsh8JO57OoFr_rxm54B7LpQ=Em413G4Hw@mail.gmail.com' \
    --to=bc3141592@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=kjambunathan@gmail.com \
    --cc=n.goaziou@gmail.com \
    /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).