*Introduction* Provides a template operator 'latexrender' which renders LaTeX formulas on the fly as bitmaps. Based on http://www.mayer.dial.pipex.com/tex.htm#latexrender of which only the file class.latexrender.php is used by the template operator. *Description* INSTALL ======= - Make sure you have the required packages on your server (LaTeX). For info look at the original latexrender page ( http://www.mayer.dial.pipex.com/tex.htm#latexrender ) - Unpack the archive available from http://pubsvn.ez.no/websvn/dl.php...ion%2Flatex%2F&rev=0&isdir=1 into your extension directory - Activate the latex extension in your admin interface USAGE ===== {$inputstring|latexrender(array(,, ))} The $inputstring should contain your LaTeX string without $ or \( )\ (the LaTeX math delimiters) Additional parameters are , , which are by default set to ('png',12,120) Returns the URL to the converted image. WHERE TO USE ============ You can use this operator anywhere, but it is probably most useful in a new content class. Just add a plain text field and use the operator in a custom template for this class as described below. A package is provided in the distribution (made in a 3.6.1 site). However, you may as well add a custom tag for xml text fields. An example template and settings are provided. EXAMPLE TEMPLATE CODE ===================== Please note the use of escapes of the closing } in the strings used in the template code. This is required to avoid a clash with other template code. For versions lower than 3.6, you will need to use the old syntax ... but it should work. {def $myformulas=array('\sqrt{2\}', '\int_{0\}^{1\}','\displaystyle\int_{0\}^{1\}\frac{x^{4\}(1-x)^{4\}\}{1+x^{2\}\}dx=\frac{22\}{7\}-\pi')} {foreach $myformulas as $formula}

Formula

{$formula}
{/foreach} Have fun -paul *Changelog* [0.1] - Initial upload, provides latexrender operator for generating png or gif representations of LaTeX formulas. Only tested on Linux. [0.2] - Added some more settings as an example how to use it as a custom tag. - Added a package with an example object, class definition and template - Added a note here on where to use it - Added a tar.gz archive from pubsvn.ez.no