Using equations in moodle messages

Using equations in moodle messages

by Stephan Bach -
Number of replies: 2

Hi all,

is it possible to use the MathJax filter to display equations in moodle messages? If I type something like \(\frac 1 2\) into a message in the mobile app, it is nicely rendered as \(\frac 1 2\). But if I use the same expression on the desktop-version I only get plain text.

Do I have to enable the MathJax filter for the messages at some hidden point to make this work? (It did work in the past though.)

Thanks, Stephan.

Average of ratings: -
In reply to Stephan Bach

Re: Using equations in moodle messages

by Daniel Thies -
Picture of Core developers Picture of Plugin developers Picture of Testers

Hi Stephan,

The message system was redone in 3.8 on the web version so that messages are available using ajax. The messages are lazy loaded meaning that they load after MathJax has already run on the page. The message handler should notify MathJax filter to process the new content, but does not.

A work around for the present is to enable the TeX notation filter in system context. The mobile app was just recently fixed so that was not necessary to use it. It is great that is working now.

Daniel

Average of ratings: Useful (1)