SPECIAL NOTICE
Malicious code was found on the site, which has been removed, but would have been able to access files and the database, revealing email addresses, posts, and encoded passwords (which would need to be decoded). However, there is no direct evidence that any such activity occurred. REGARDLESS, BE SURE TO CHANGE YOUR PASSWORDS. And as is good practice, remember to never use the same password on more than one site. While performing housekeeping, we also decided to upgrade the forums.
This is a site for discussing roleplaying games. Have fun doing so, but there is one major rule: do not discuss political issues that aren't directly and uniquely related to the subject of the thread and about gaming. While this site is dedicated to free speech, the following will not be tolerated: devolving a thread into unrelated political discussion, sockpuppeting (using multiple and/or bogus accounts), disrupting topics without contributing to them, and posting images that could get someone fired in the workplace (an external link is OK, but clearly mark it as Not Safe For Work, or NSFW). If you receive a warning, please take it seriously and either move on to another topic or steer the discussion back to its original RPG-related theme.

Allow maths expressions in forum posts?

Started by Wtrmute, February 20, 2023, 12:31:15 PM

Previous topic - Next topic

Wtrmute

I know this is a long shot, but sometimes I would like to include mathematical expressions in forum posts, typically to express dice probability etc. Generally, on the Web, this is done by including the MathJax javascript library and letting it render on the client side, so it does not place any undue burden on the server.

I took the liberty of looking up whether there was a prepackaged solution for the forum software this site uses, and found this one. I'm not affiliated with it in any way, but it seems to do the job adequately well.

Thanks for your time in any case!

brettmb

I'll look into it, but I'm trying to keep the load times as low as possible, and this library would likely just add to the burden.

Wtrmute

Thanks! I don't think it will make much of a difference in load times; these libraries are massively optimised, being used in Wikipedia and StackExchange and all sorts of huge sites (although I generally prefer KaTeX since it's even faster, the SMF mod only has MathJax). And since the rendering is on the client-side, the most that could happen is that in threads where there are a whole lot of formulas, the later ones might not immediately show up as rendered formulas and instead as the LaTeX source.

Still, if you decide it's too much trouble, I'll understand. It's not a dealbreaker by any means. In the very worst case I can always attach a PNG with the rendered formulas to a post, if they are absolutely necessary for understanding what the heck I'm talking about.