Hallo,
according to the documentation of org-html-table-row-tags in ox-html.el the following code can be used to assign different CSS classes to alternating rows:
(setq org-html-table-row-tags
(cons '(if head
\"
\"
(if (= (mod nline 2) 1)
\"
\"
\"
\"))
\"
\"))
This does not work for me because of these problems:
eval: Symbol's value as variable is void: head
=: Symbol's value as variable is void: nline
My knowledge of elisp is very limited, but I assume fixing these errors would require defining head and a line counter nline around ll. 2976 in ox-html, at least the latter might be simple to fix.
However, I would suggest to implement this differently: have an option "org-html-alternating-table-row-classes" (or similar) that - if not nil - is used for alternating class names. Or - in keeping with hardwired class names like "org-ul" - always use "org-row-odd" and "org-row-even" if "org-html-alternating-table-row-classes" is not nil. Users who would prefer different class names could then still come up with their own definition of org-html-table-row-tags if needed.
Warm regards,
Stefan
--
Dr. Stefan Vollmar, Dipl.-Phys.
Head of IT group
Max-Planck-Institut für neurologische Forschung
Gleueler Str. 50, 50931 Köln, Germany
Tel.: +49-221-4726-213 FAX +49-221-4726-298
Tel.: +49-221-478-5713 Mobile: 0160-93874279
E-Mail: vollmar@nf.mpg.de http://www.nf.mpg.de