Sha256: 0cd6c9aa9599a6f5b03818680acaf9c41d6a3d5e14c417515f1d66e3177fb6c0

Contents?: true

Size: 1.25 KB

Versions: 9

Compression:

Stored size: 1.25 KB

Contents

<html>
<head>
<title>MathJax Dynamic Math Test Page</title>
<!-- Copyright (c) 2010 Design Science, Inc. -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" >

<script src="../MathJax.js">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js"],
    jax: ["input/TeX","output/HTML-CSS"],
    tex2jax: {inlineMath: [["$","$"],["\\(","\\)"]]}
  });
</script>

</head>
<body>

<script>
  //
  //  Use a closure to hide the local variables from the
  //  global namespace
  //
  (function () {
    var QUEUE = MathJax.Hub.queue;  // shorthand for the queue
    var math = null;                // the element jax for the math output.

    //
    //  Get the element jax when MathJax has produced it.
    //
    QUEUE.Push(function () {
      math = MathJax.Hub.getAllJax("MathOutput")[0];
    });

    //
    //  The onchange event handler that typesets the
    //  math entered by the user
    //
    window.UpdateMath = function (TeX) {
      QUEUE.Push(["Text",math,"\\displaystyle{"+TeX+"}"]);
    }
  })();
</script>

Type some TeX code and press RETURN:<br/> 
<input id="MathInput" size="50" onchange="UpdateMath(this.value)" />
<p>

<div id="MathOutput">
You typed: ${}$
</div>

</body>
</html>

Version data entries

9 entries across 9 versions & 3 rubygems

Version Path
amiba-1.0.2 lib/amiba/frontend/public/javascript/MathJax/test/sample-dynamic.html
amiba-1.0.1 lib/amiba/frontend/public/javascript/MathJax/test/sample-dynamic.html
amiba-1.0.0 lib/amiba/frontend/public/javascript/MathJax/test/sample-dynamic.html
amiba-0.0.9 lib/amiba/frontend/public/javascript/MathJax/test/sample-dynamic.html
gollum-1.3.1 lib/gollum/frontend/public/javascript/MathJax/test/sample-dynamic.html
jugyo-gollum-1.3.1 lib/gollum/frontend/public/javascript/MathJax/test/sample-dynamic.html
gollum-1.2.1 lib/gollum/frontend/public/javascript/MathJax/test/sample-dynamic.html
gollum-1.3.0 lib/gollum/frontend/public/javascript/MathJax/test/sample-dynamic.html
gollum-1.2.0 lib/gollum/frontend/public/javascript/MathJax/test/sample-dynamic.html