Using MathML with Moodle

In my previous blog post Generating MathML Code for Equations with MathType I showed how to get MathML for a equation you have created with MathType. In this post I show how this MathML code can be inserted to a Moodle page. You need MathJax filter enabled in Moodle.

If you insert the MathML code into a Moodle page it is unlikely to be displayed correctly. When I inserted the MathML code into a Moodle page this is how it was displayed.

MathML is displayed as garbage Moodle
Moodle page with incorrect display of math symbols

This issue is discussed in various Moodle forums. It is quick and easy to correct this. You need to change settings so that MathML will be correctly displayed by the current MathJax filter. Go to:

Site administration > Plugins > Filters > MathJax > Additional equation delimiters and add the delimiter <math to the existing delimiters and save changes.

Screen showing how to add <math as an additional delimiter
Add additional delimiters to MathJax filter

Now when you refresh the page where you inserted MathML code it should correctly display it.

Correctly Displayed MathML Equation
Correctly Displayed MathML Equation

 

Leave a Reply

Your email address will not be published. Required fields are marked *