How can I enable the use of math in my html webpage

I have a blog where people can post their comments. My problem is that I need people to be able to use math formulas using latex syntax. I cannot make any changes to the server. I can only paste the script into my HTML page. Please help.

+5
source share
5 answers

You can use jsMath to solve this problem. This is all client-side javascript, but you must reference the jsMath library to use your functions.

+4
source

MathJax. Blogger: MathJax

script:

<script src="http://www.mathjax.org/MathJax/MathJax.js">
  //
  //  This script call is what gets MathJax loaded and running
  //
  MathJax.Hub.Config({
    // Only needed if to do more configuration within the page
    delayStartupUntil: "onload",
    // input is TeX and output is HTML-CSS 
    jax: ["input/MathML", "input/TeX", "output/HTML-CSS"],    format
    // use the tex2jax preprocessor
    extensions: ["tex2jax.js"],              
    tex2jax: {
      // uncomment to use $...$ for inline math
      inlineMath: [['$','$'], ['\\(','\\)']],
      // set to 1 to allow \$ to produce a dollar sign 
      processEscapes: 1                      
    }
  });
</script>
+3

LaTeX 4 Web, LaTeX HTML.

+1

All Articles