An earlier answer (“converting to HTML”) addresses the issue of converting existing (La)TeX documents for viewing on the Web as HTML. All the present techniques are somewhat flawed: the answer explains why.
However, things are changing, with better font availability, cunning HTML programming and the support for new Web standards.
Now, however, free Unicode-encoded OpenType fonts, with coverage of mathematical symbols, are starting to appear. The much-heralded STIX fonts are now available on CTAN, and a tweaked version (XITS) and Asana Math are also available. The STIX project has still not released macros for using the fonts, but the unicode-math package will do what is necessary under XeTeX and LuaTeX, and the fonts can of course be used in browsers.
Conversion of (La)TeX source to XML is already available (through TeX4ht at least), and work continues in that arena. The alternative, authoring in XML (thus producing documents that are immediately Web-friendly, if not ready) and using (La)TeX to typeset is also well advanced. One useful technique is transforming the XML to LaTeX, using an XSLT stylesheet or code for an XML library, and then simply using LaTeX; alternatively, one may typeset direct from the XML source.
The MathJax engine will process the
content of LaTeX
‘environments’ in an HTML document, to produce mathematical
output that may (for example) be cut-and-pasted into other programs.
Incorporation into your document can be as simple as incorporating:
into the header of your HTML document, though the MathJax project’s site also allows you to download your own copy and install it on one of your servers. MathJax is open source software, so you could, in principle, extend it to do even more eccentric tasks.
An approach different from (La)TeX conversion is taken by the GELLMU Project. Its article XML document type, which has a markup vocabulary close to LaTeX that can be edited using LaTeX-like markup (even though it is not LaTeX — so far), comes with translators that make both PDF (via pdflatex) and XHTML+MathML. Such an approach avoids the inherent limitations of the “traditional” (La)TeX translation processes, which have traps that can be sprung by unfettered use of (La)TeX markup.
Browser plug-ins, that deal with SVG are already available (Adobe offer one, for example). More recently, the open source graphics editor Inkscape has appeared, and has been reported to be useful for SVG-related work in at least one TeX-related project. Be aware that the developers of Inkscape have no illusions about being able to replace commercial software, yet…
The disadvantage of the TechExplorer approach is that it places the onus on the browser user; and however technically proficient you are, it’s never safe to assume too much of your readers. An interesting alternative is MathTeX, which sits on your server as a CGI script, and you use it to include your TeX, in your HTML, as if it were an image:
(Mathtex supersedes the author’s earlier mimetex.)
This answer last edited: 2011-10-17