index.html 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>MathJax Test Page</title>
  5. <!-- Copyright (c) 2009-2013 The MathJax Consortium -->
  6. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  7. <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  8. <script type="text/x-mathjax-config">
  9. //
  10. // Do NOT use this page as a template for your own pages. It includes
  11. // code that is needed for testing your site's installation of MathJax,
  12. // and that should not be used in normal web pages. Use sample.html as
  13. // the example for how to call MathJax in your own pages.
  14. //
  15. MathJax.HTML.Cookie.Set("menu",{});
  16. MathJax.Hub.Config({
  17. extensions: ["tex2jax.js"],
  18. jax: ["input/TeX","output/HTML-CSS"],
  19. "HTML-CSS": {
  20. availableFonts:[],
  21. styles: {".MathJax_Preview": {visibility: "hidden"}}
  22. }
  23. });
  24. MathJax.Hub.Register.StartupHook("HTML-CSS Jax Ready",function () {
  25. var FONT = MathJax.OutputJax["HTML-CSS"].Font;
  26. FONT.loadError = function (font) {
  27. MathJax.Message.Set("Can't load web font TeX/"+font.directory,null,2000);
  28. document.getElementById("noWebFont").style.display = "";
  29. };
  30. FONT.firefoxFontError = function (font) {
  31. MathJax.Message.Set("Firefox can't load web fonts from a remote host",null,3000);
  32. document.getElementById("ffWebFont").style.display = "";
  33. };
  34. });
  35. (function (HUB) {
  36. var MINVERSION = {
  37. Firefox: 3.0,
  38. Opera: 9.52,
  39. MSIE: 6.0,
  40. Chrome: 0.3,
  41. Safari: 2.0,
  42. Konqueror: 4.0,
  43. Unknown: 10000.0 // always disable unknown browsers
  44. };
  45. if (!HUB.Browser.versionAtLeast(MINVERSION[HUB.Browser]||0.0)) {
  46. HUB.Config({
  47. jax: [], // don't load any Jax
  48. extensions: [], // don't load any extensions
  49. "v1.0-compatible": false // skip warning message due to no jax
  50. });
  51. setTimeout('document.getElementById("badBrowser").style.display = ""',0);
  52. }
  53. })(MathJax.Hub);
  54. MathJax.Hub.Register.StartupHook("End",function () {
  55. var HTMLCSS = MathJax.OutputJax["HTML-CSS"];
  56. if (HTMLCSS && HTMLCSS.imgFonts) {document.getElementById("imageFonts").style.display = ""}
  57. });
  58. </script>
  59. <script type="text/javascript" src="../MathJax.js"></script>
  60. <style>
  61. .warning {
  62. color: #800020;
  63. background-color: #FFF8F8;
  64. border: 2px solid red;
  65. margin: 1em 5em;
  66. padding: 1em;
  67. }
  68. </style>
  69. </head>
  70. <body>
  71. <noscript>
  72. <div style="color:#CC0000; text-align:center">
  73. <b>Warning: <a href="http://www.mathjax.org/">MathJax</a>
  74. requires JavaScript to process the mathematics on this page.<br />
  75. If your browser supports JavaScript, be sure it is enabled.</b>
  76. </div>
  77. <hr>
  78. </noscript>
  79. <blockquote>
  80. <h1>MathJax Test Page</h1>
  81. <p>
  82. If you see typeset mathematics below, then MathJax is working. If you see
  83. TeX code instead, MathJax is not working for you.
  84. </p>
  85. <!------------------------------------------------------------------------>
  86. <hr>
  87. <p>
  88. \[\int_{\; - 1}^{\;0} {dy\int_{\;2}^{\;1 - y} {f(x,y)dx} } \]
  89. </p>
  90. <div style="color:green">
  91. <div style="text-align:center; color:red; font-size:120%" class="MathJax_Preview">
  92. MathJax is not working!
  93. </div><script type="math/tex; mode=display">
  94. \bf MathJax\ Appears\ to\ be\ Working!
  95. </script>
  96. </div>
  97. <hr>
  98. <!------------------------------------------------------------------------>
  99. <div id="badBrowser" style="display:none">
  100. <div class="warning">
  101. <b>WARNING</b>: The browser you are using does not appear to support
  102. MathJax, so we can't test if MathJax is working. Please try a different
  103. browser, or a newer version of your browser in order to test MathJax.
  104. </div>
  105. <hr>
  106. </div>
  107. <!------------------------------------------------------------------------>
  108. <div id="imageFonts" style="display:none">
  109. <div class="warning">
  110. <b>WARNING</b>: The browser you are using does not seem to support web-based
  111. fonts, so we can't test the MathJax web fonts with this browser (image fonts
  112. have been used instead). Please try a different browser, or a newer version
  113. of your browser in order to test MathJax's web-based fonts.
  114. </div>
  115. <hr>
  116. </div>
  117. <!------------------------------------------------------------------------>
  118. <div id="noWebFont" style="display:none">
  119. <div class="warning">
  120. <b>WARNING</b>: MathJax's web fonts don't seem to be available. Be sure you have
  121. the <code>MathJax/fonts</code> directory in place before continuing.
  122. If you fail to install these fonts, MathJax will not
  123. work properly with some browsers. If you can't install the image fonts,
  124. be sure to set the <code>noImageFonts</code> parameter in your MathJax configuration
  125. (either <code>MathJax/config/MathJax.js</code>, or the
  126. <code>MathJax.Hub.Config()</code> call in your web page).
  127. </div>
  128. <hr>
  129. </div>
  130. <!------------------------------------------------------------------------>
  131. <div id="ffWebFont" style="display:none">
  132. <div class="warning">
  133. <b>WARNING</b>: You are trying to load MathJax from a remote site where the
  134. web-based fonts are not set up to be shipped to Firefox properly. See the
  135. <a href="../docs/html/installation.html#notes-about-shared-installations">discussion
  136. of Firefox's same-origin policy</a> in the MathJax documentation for more
  137. details.
  138. </div>
  139. <hr>
  140. </div>
  141. <!------------------------------------------------------------------------>
  142. <p>
  143. Once you have MathJax working properly, view the <a
  144. href="index-images.html">image mode test page</a> to make sure that the
  145. image fallback mode is working as well.
  146. </p>
  147. </blockquote>
  148. </body>
  149. </html>