# Tex math formula rendering not working on math.stackexchange.com but does work on other sites

I'm running Ubuntu 12.04. In both Chromium and Firefox (ver 25), math.stackexchange.com fails to render the math formulas.

However, if I go to http://www.mathjax.org/, I see correctly rendered math formulas on the upper right of their home page.

Furthermore, if I try to post this question in meta.math.stackexchange.com I am blocked. (I'm not sure why I'm blocked. Maybe an admin can move this post for me, if necessary? And I apologize to the admin for the trouble.) EDIT: the login blocking and the math rendering appear to be related. It seems that meta.math.stackexchange.com and math.stackexchange.com are incompatible with HTTPS-Everywhere.

I have also tested this in Chromium ver 31 with no plugins and no special settings/options—and I experience the same math rendering problem.

In Firefox I made sure to whitelist mathjax.org and stackexchange.com in Ghostery and No-script. However, that didn't help. Even allowing scripts globally in No-script doesn't resolve the issue.

It seems that math.stackexchange.com fails with certain plugins or configurations while mathjax.org doesn't have a problem with these same things. At least that's my guess. I don't know what to conclude about Chromium not working. But I use Firefox normally anyway, so I don't care about Chromium not working.

Thanks for any help.

• Weird. You may find someone here has an answer; you may also find better support over at the MathJax website. – dfeuer Jan 10 '14 at 6:38
• The MathJax team does monitor these forums, so we see the questions about MathJax posted here (and I personally prefer they are not posted to multiple places). So asking here is fine, especially with this question, which seems to be specific to SE. Are there any error messages in the browser console when MathJax isn't working? And when you say "fails to render" does nothing happen, or does the math go grey and then not render, or do you get "math processing error" messages? – Davide Cervone Jan 10 '14 at 19:39
• Hm, works fine for me, I run the same thing. – Alexander Gruber Jan 10 '14 at 19:40
• @DavideCervone - Thanks! Yes, I do see some relevant errors! In particular, (1) [18:27:56.416] ReferenceError: MathJax is not defined @ cdn.sstatic.net/Js/mathjax-editing.en.js?v=a09844f7b738:3 (2) [18:27:55.667] Blocked loading mixed active content "cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS_HTML" @ math.stackexchange.com/questions/634230/… – MountainX Jan 10 '14 at 23:31
• I just searched and found this: goo.gl/IMwgze Relevant? "The long-anticipated inclusion of mixed-content blocking in Mozilla Firefox is now at hand, with the security feature showing up in the just-released Firefox 23. The feature, which helps defend users against certain kinds of man-in-the-middle attacks, is on by default in the new browser." – MountainX Jan 10 '14 at 23:35
• @DavideCervone - "fails to render" means nothing that is visible to the user happens. However, I think the browser console message may be the info you need. I added both mathjax.org and stackexchange.com to Preferences > Security > Exceptions. That did not fix it. – MountainX Jan 10 '14 at 23:46
• @AlexanderGruber - are you on Firefox >= version 23? What security plugins do you have? The relevant security changes seems to have been implemented in FF version 23... – MountainX Jan 10 '14 at 23:51
• meta.math.stackexchange.com/questions/6198/… – minopret Feb 8 '14 at 20:35

If you are using https: to access Math.SE, then since MathJax is loaded from an http: URL, this will lead to the "blocking mixed access content" message that you have identified above.

I have created a Greasemonkey script that will load MathJax from the CDN's https: address in this case (but will do nothing if you are using http:). You need to have Greasemonkey installed (See this post for pointers to Greasemonkey and work-alikes for other browsers). Once it is installed, clicking on the following link should ask if you want to install the user script.

Let me know if this script doesn't work for you. I have tested in with Firefox 26 on Mac OS X, but it should work on other browsers and OS's.

• Thank you! That fixes the issue. (There is a small bit of delay in rendering.) – MountainX Jan 11 '14 at 23:02
• Would be best if this worked on all stackexchange sites. – endolith Feb 5 '14 at 21:23
• @endolith, You can edit the @include lines at the top of the script (most GreaseMonkey implementations allow that from within the browser) to add other sites if you want. You might even be able to use wildcards in the site name (I'm not sure). You might also want to check out SOUP for a more sophisticated solution. – Davide Cervone Feb 5 '14 at 21:30
• The stackexchange team could add the Mathjax JS as protocol-relative URL, that would solve the issue! – theDmi Feb 10 '14 at 15:14

Sounds to me as if your browsers are trying to block mixed content. If so, the solution I'm currently familiar with is not too elegant.

A Firefox solution: (For other browsers, apply trivial generalization.)
Notice the shield icon next to the location bar.
Click it and instead of the option "Keep Blocking", choose "Disable Protection on This Page". This should fix the problem until you refresh the page, which is pretty lousy.

For a permanent solution, you can go to Firefox's "about:config", and change the boolean value of security.mixed_content.block_active_content to 'true'. I also find this solution lousy, as it is a potential security concern.

As to why this problem so suddenly loomed, I myself am perturbed.

• Yes, you nailed it exactly. Thank you. This seems to explain why the problem has arisen: Mixed Content Blocking Appears in Firefox 23 | Threatpost - English - Global - threatpost.com threatpost.com/mixed-content-blocking-appears-in-firefox-23/… – MountainX Jan 10 '14 at 23:40
• I agree with you about the unsatisfactoriness of security.mixed_content.block_active_content to 'true'. I'm not going to do that. Hopefully someone reading this will know of a proper solution. – MountainX Jan 10 '14 at 23:53
• I guess one solution would be to access math.SE via http:// rather than https://. (When I log into math.SE, that's what I get, so I don't think there is any reason you could not do that.) Alternatively, you could create a user script that checks if MathJax is loaded, and if not, loads it from the MathJax CDN's https:// address. If I get a minute, I'll see if I can whip one up. – Davide Cervone Jan 11 '14 at 0:47
• Is there a way to add an option to make permanent exceptions to block_active_content for certain domains? – Geremia Mar 14 '14 at 18:23