You are here

README.txt in MathJax: LaTeX for Drupal 7.2

Same filename and directory in other branches
  1. 8.2 README.txt
  2. 6 README.txt
  3. 7 README.txt
  4. 3.0.x README.txt
This module integrates the MathJax library into your Drupal site. MathJax is the
modern JavaScript-based LaTeX rendering solution for the Internet.

By default, MathJax source is loaded automatically from the Internet using the 
MathJax Content Delivery Network (CDN).

There are two MathJax configuration options: Text format (recommended), or 
Custom.

If you select "Text format", MathJax will be available as a text filter.
Mathematics inside the default delimiters will be rendered by MathJax. The
default math delimiters are $$...$$ and \[...\] for displayed mathematics, and
$...$ and \(...\) for in-line mathematics. You must add the MathJax filter to a 
text format and put MathJax at the bottom of the filter processing order.

You may select "Custom" if you need a more specific configuration. "Custom" is
the default when upgrading.

If you want to emulate the previous behavior with a custom configuration, use
the following:

MathJax.Hub.Config({
  extensions: ["tex2jax.js"],
  jax: ["input/TeX","output/HTML-CSS"],
  tex2jax: {
    inlineMath: [ ['$','$'], ['\\(','\\)'] ],
    processEscapes: true
  }
});

INSTALLATION
============

Using the MathJax CDN (recommended)
-------------------------------

1. Install and enable this module.

2. Add the MathJax filter to an existing or new text format under 
   Administration >> Configuration >> Text Formats. Put the MathJax filter at
   the bottom of the "Filter processing order".

3. Test it by adding a LaTeX formula between '$' in any node body (for example: 
   $2 + 2 = 4$). Select the body text format you configured on the Text Formats
   administration screen.


Using a local copy of MathJax (relies on libraries module)
----------------------------------------------------------

1. Install and enable this module.

2. Install and enable "libraries". See http://drupal.org/project/libraries.

3. Install the third-party MathJax software:
     Download MathJax source from the MathJax website.
     Un-archive it into your "libraries" directory (e.g. sites/all/libraries).
     You may need to create the "libraries" directory first.
     Rename it to "mathjax" (lower case).
Relying on the libraries module to locate the 'mathjax' folder allows you to
place it in a site-specific directory (e.g. sites/mysite/libraries) or in the
default directory (e.g. sites/all/libraries). Site-specific versions are
selected preferentially.

4. Follow from step #2 above.

ORIGINAL AUTHOR
===============
Module written by Thomas Julou.
http://drupal.org/user/273952

MAINTAINER(S)
=============
2013: Chris McCafferty (cilefen) https://drupal.org/u/cilefen
2014: P. Magunia (pmagunia) https://www.drupal.org/u/pmagunia

File

README.txt
View source
  1. This module integrates the MathJax library into your Drupal site. MathJax is the
  2. modern JavaScript-based LaTeX rendering solution for the Internet.
  3. By default, MathJax source is loaded automatically from the Internet using the
  4. MathJax Content Delivery Network (CDN).
  5. There are two MathJax configuration options: Text format (recommended), or
  6. Custom.
  7. If you select "Text format", MathJax will be available as a text filter.
  8. Mathematics inside the default delimiters will be rendered by MathJax. The
  9. default math delimiters are $$...$$ and \[...\] for displayed mathematics, and
  10. $...$ and \(...\) for in-line mathematics. You must add the MathJax filter to a
  11. text format and put MathJax at the bottom of the filter processing order.
  12. You may select "Custom" if you need a more specific configuration. "Custom" is
  13. the default when upgrading.
  14. If you want to emulate the previous behavior with a custom configuration, use
  15. the following:
  16. MathJax.Hub.Config({
  17. extensions: ["tex2jax.js"],
  18. jax: ["input/TeX","output/HTML-CSS"],
  19. tex2jax: {
  20. inlineMath: [ ['$','$'], ['\\(','\\)'] ],
  21. processEscapes: true
  22. }
  23. });
  24. INSTALLATION
  25. ============
  26. Using the MathJax CDN (recommended)
  27. -------------------------------
  28. 1. Install and enable this module.
  29. 2. Add the MathJax filter to an existing or new text format under
  30. Administration >> Configuration >> Text Formats. Put the MathJax filter at
  31. the bottom of the "Filter processing order".
  32. 3. Test it by adding a LaTeX formula between '$' in any node body (for example:
  33. $2 + 2 = 4$). Select the body text format you configured on the Text Formats
  34. administration screen.
  35. Using a local copy of MathJax (relies on libraries module)
  36. ----------------------------------------------------------
  37. 1. Install and enable this module.
  38. 2. Install and enable "libraries". See http://drupal.org/project/libraries.
  39. 3. Install the third-party MathJax software:
  40. Download MathJax source from the MathJax website.
  41. Un-archive it into your "libraries" directory (e.g. sites/all/libraries).
  42. You may need to create the "libraries" directory first.
  43. Rename it to "mathjax" (lower case).
  44. Relying on the libraries module to locate the 'mathjax' folder allows you to
  45. place it in a site-specific directory (e.g. sites/mysite/libraries) or in the
  46. default directory (e.g. sites/all/libraries). Site-specific versions are
  47. selected preferentially.
  48. 4. Follow from step #2 above.
  49. ORIGINAL AUTHOR
  50. ===============
  51. Module written by Thomas Julou.
  52. http://drupal.org/user/273952
  53. MAINTAINER(S)
  54. =============
  55. 2013: Chris McCafferty (cilefen) https://drupal.org/u/cilefen
  56. 2014: P. Magunia (pmagunia) https://www.drupal.org/u/pmagunia