bugtex4ht - Bugs: bug #426, htlatex mathjax option breaks...

 
 
Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

bug #426: htlatex mathjax option breaks references

Submitted by:  Matthew Towers <mjt>
Submitted on:  Wed Jun 5 19:33:56 2019  
 
Category: NonePriority: 5 - Normal
Severity: 5 - NormalStatus: Wont Fix
Privacy: PublicAssigned to: None
Open/Closed: Closed

Mon Aug 19 01:10:09 2019, comment #2:

seems there is no more to do with mathjax references (unfortunately)? closing, feel free to reopen if that's wrong ...

Karl Berry <karl>
Project Administrator
Thu Jun 6 13:14:55 2019, comment #1:

This is something that is not easily solvable. The labels inside math are not processed by LaTeX at all, so the labels are not saved. MathJax itself supports some form of referencing, when \eqref command is found in the HTML code. So one possible solution is to provide a custom command, that is written as \eqref in the HTML. See this answer of mine:

https://tex.stackexchange.com/a/378359/2891

It also discuss another option, which is pre-processing of the TeX file, but it is a bit more complicated. It is necessary to use a custom command to reference to math, because if normal \ref was used, you would lose the referencing support for tables, sections, etc.

Michal Hoftich <michal_h21>
Project Member
Wed Jun 5 19:33:56 2019, original submission:

Using htlatex with the mathjax option causes references created with \ref to fail. Minimal example:

\documentclass{article}
\begin{document}
\begin{equation} \label{a} a=b \end{equation}
\ref{a}
\end{document}

...saved as minimal.tex. The command

htlatex minimal "html"

produces an html file with a working link at \ref{a}, but

htlatex minimal "html,mathjax"

produces just (??) even after multiple passes. Debian buster, tex4ht.c 2018-06-30-15:36 (from the debian repos)

Matthew Towers <mjt>

 

Attached Files
file #315:  mininal.html added by murugan (926B - text/html - you need to install tex4ht full package or install texlive, its default installed.)
file #316:  mininal0x.png added by murugan (3kB - image/png - you need to install tex4ht full package or install texlive, its default installed.)
file #317:  mininal.tex added by murugan (114B - application/octet-stream - you need to install tex4ht full package or install texlive, its default installed.)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by karl (Posted a comment)
  • -unavailable- added by murugan (Updated the item)
  • -unavailable- added by murugan (Its working for me. Check the attached file. I think you need to install tex4ht full package. In texlive it default installed. check it)
  • -unavailable- added by michal_h21 (Posted a comment)
  • -unavailable- added by mjt (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    6 latest changes follow.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon Aug 19 01:10:09 2019karlStatusNone=>Wont Fix
      Open/ClosedOpen=>Closed
    Fri Jun 7 04:16:33 2019muruganAttached File-=>Added mininal.html, #315
      Attached File-=>Added mininal0x.png, #316
      Attached File-=>Added mininal.tex, #317
      Carbon-Copy-=>Added -unavailable-
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup+gray