Article in Education & LMS

Ever since the born of LearnPress, we received a large amount of questions about how to add Latex formulas to LearnPress and WordPress. As LearnPress grows larger, the number of inquiries increases everyday due to the increasing number of large institutions, schools and universities using LearnPress as their main LMS. Indeed, implementing Latex in WordPress can be done very quick and simple using a lightweight WordPress plugin. Once you install the plugin, you can implement Latex into your site and your LearnPress courses’ content right away. In this article, we will dig deeper and provide a step by step tutorial of how to make that happen.

The plugin we will use in this tutorial is called MathJax-LaTeX.

Mathjax is a latex processor which allows people to display embed latex or mathml on html documents. Working as a WordPress plugin, mathjax will help you quickly render math equations using their javascript structure and place it into your post’s content. You can load the script from your own server, or from CDN to maximize the speed and performance of the site.

There are currently 4000 sites using Mathjax as their Latex processor and the plugin has accumulated a number of good reviews and a reputation of quick response and quick update. The latest version has been updated in only around a month ago and the plugin is compatible with the latest version of WordPress. For that reason, we can verify that Mathjax can be a good, stable plugin for our long-term use.

How to install Mathjax:

1. Go to your WordPress dashboard
2. Go to Plugins > Add new and search for Latex. You will see mathjax right on top of the search query. Or you could just search for mathjax.
3. Install and activate the plugin
4. That’s it.  Mathjax is installed and activated on your site. Now it’s time to use it.

How to use LaTeX with Mathjax

Just place your latex code wherever you want.

For example, you can use this code to display the famous equation of the theory of relativity

$E=mc^2$

or you can also use native mathjax syntax $$E=mc^2$$  or (E=mc^2).

If you want to use both of these syntax types, you can place the shortcode  [mathjax] into your article and you’re free to use any syntax type you want.

Finally, you can use the shortcode [nomathjax] to disable mathjax for certain pages.

Below are some examples of LateX displayed on Eduma using MathJax

Latex on LearnPress’s Course Description Page

Latex on LearnPress’s Lesson

Latex on LearnPress’s Quiz

No comments yet! You be the first to comment.