[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] Specifying ATTR_HTML class for source blocks
From: |
Martin G . Skjæveland |
Subject: |
[O] Specifying ATTR_HTML class for source blocks |
Date: |
Thu, 3 Oct 2019 10:10:54 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 |
Hi all,
I would like my source blocks to be exported to HTML as textareas with a
class attribute -- so I can later use this in my javascript code. I can
use ":textarea t" [1], but it seems that other attributes except width
and height are ignored:
#+ATTR_HTML: :textarea t :class testing
#+BEGIN_SRC n3
My code
#+END_SRC
gives
<textarea cols="80" rows="1">My code
</textarea>
and, testing without ":textarea",
#+ATTR_HTML: :class testing
#+BEGIN_SRC n3
My code
#+END_SRC
gives
<pre class="src src-n3">My code
</pre>
Preferably, I want the following html:
<textarea cols="80" rows="1" class="testing">My code
</textarea>
Is there a way to achieve this?
Thanks,
Martin
[1] https://orgmode.org/manual/Text-areas-in-HTML-export.html
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [O] Specifying ATTR_HTML class for source blocks,
Martin G . Skjæveland <=