When I use the \today macro, I cannot get, in my .html, the display in various languages when I compile the following file from michal-h21 @michal.h21 and sty file of alternative4ht: all my dates are in english!

I compile with make4ht -ul filename . My pdf is fine with lualatex....


\setmainfont{TeX Gyre Termes}
\newfontfamily\greekfont{Linux Libertine O}
\newfontfamily\russianfont{Linux Libertine O}

Praha je hlavní a současně největší město České republiky a 15. největší město Evropské unie. Leží mírně na sever od středu Čech na řece Vltavě, uvnitř Středočeského kraje, jehož je správním centrem, ale jako samostatný kraj není jeho součástí. Je sídlem velké

Πράγα (τσέχικα: Praha), είναι η πρωτεύουσα και μεγαλύτερη πόλη της Τσεχίας. Χτισμένη στον ποταμό Μολδάβα (Vlt}

га (чеш. Praha [ˈpraɦa]) — город и столица Чехии; административный центр Среднечешского края и двух его районов —

 प्राग युरोप के चेकोस्लोवाकिया देश की राजधानी है। 


1 Answer 1


I've just added basic support for language definition files loading, please update helpers4ht. This is the current result:

enter image description here

  • I tried you solution, but if you set \setmainlanguage{french}, I get (/texlive/texmf-dist/tex/latex/polyglossia/gloss-french.ldf ! LuaTeX error [\directlua]:1: attempt to index global 'polyglossia' (a nil value) stack traceback: [\directlua]:1: in main chunk. l.14 \directlua{polyglossia.load_frpt()}.I put enter to carry and it compiles well with the french date in the html. I do not have errors when I set \setmainlanguage{czech} or even \setmainlanguage{german}....
    – Koala
    Commented Dec 31, 2015 at 8:43
  • On a side note, for greek, and only for greek, I get the error, even before updating the package, Runaway argument? { ! Paragraph ended before \printlang was complete. <to be read again> \par l.25 ...· στον ποταμό Μολδάβα (Vlt} ? ! Too many }'s. \textgreek ...guage {greek}\printlang {#1}\egroup l.25 ...· στον ποταμό Μολδάβα (Vlt} when I compile. DO you know where this comes from ?
    – Koala
    Commented Dec 31, 2015 at 8:44
  • @Koala I've added fixes for French and \textgreek. note that while it works to use \text<lang> even for texts containing paragraphs, it produces invalid HTML. it is better to use \begin{lang} for text with paragraphs.
    – michal.h21
    Commented Dec 31, 2015 at 10:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .