LaTeX Why are MathJax images not displaying on my webpage?

AI Thread Summary
MathJax has been enabled on the site, but users are experiencing issues with LaTeX images not displaying correctly, leading to frustration over the appearance and functionality. Some users report that certain LaTeX environments, like align and tabular, are not rendering properly, and there are inconsistencies in how equations appear across different browsers. The transition from image-based LaTeX to MathJax is intended to reduce server load, but users are concerned about the visual quality and usability of the new format. Feedback indicates that while MathJax can handle more equations without server strain, it may introduce rendering issues that affect the user experience. The discussion reflects a need for further adjustments and testing to optimize MathJax's implementation.
  • #101
Fredrik said:
I think the current limit is 11 hours and 40 minutes (700 minutes).

thanks
 
Physics news on Phys.org
  • #102
If there aren't any serious problems I think I'll continue to leave the MathJax up for the time being.
 
  • #103
Greg Bernhardt said:
If there aren't any serious problems I think I'll continue to leave the MathJax up for the time being.
It looks like the worst problems have been solved, so I don't see any reason to go back to the old system. Thanks for all the work you've done on this.

The most serious problem right now is that we sometimes have to insert spaces in correct LaTeX code. For example, I tried this earlier today:
Code:
|\psi\rangle\langle\psi|=\frac{1}{2}\big(|\text{here}\rangle\langle\text{here}|+|\text{here}\rangle\langle\text{there}|+|\text{there}\rangle\langle\text{here}|+|\text{there}\rangle\langle\text{there}|\big)

The result:
|\psi\rangle\langle\psi|=\frac{1}{2}\big(|\text{here}\rangle\langle\text{here}|+|\text{here}\rangle\langle\text{there}|+|\text{there}\rangle\langle\text{here}|+|\text{there}\rangle\langle\text{there}|\big)

The first "here" is displayed as "he re". The second time \rangle is followed by \langle, the parser seems to miss the backslash. And then the \text before the last "here" seems to be read as \te. It can all be fixed by inserting spaces before the keywords that cause problems:

|\psi\rangle\langle\psi|=\frac{1}{2}\big(| \text{here}\rangle\langle\text{here}|+|\text{here}\rangle \langle\text{there}|+|\text{there}\rangle\langle \text{here}|+|\text{there}\rangle\langle\text{there}|\big)

But then the last "there" is displayed as "ther e", so I have to insert another space before the last \text.

|\psi\rangle\langle\psi|=\frac{1}{2}\big(| \text{here}\rangle\langle\text{here}|+|\text{here}\rangle \langle\text{there}|+|\text{there}\rangle\langle \text{here}|+|\text{there}\rangle\langle \text{there}|\big)

Isn't there something you can do to force Firefox to display math that looks as pretty as in Internet Explorer? Is there something we can do, other than switch to IE?
 
  • #104
Fredrik said:
Isn't there something you can do to force Firefox to display math as well as Internet Explorer? Is there something I can do, other than switch to IE?

I recently forced FF to use HTML instead of MathML. It looks much better to me in FF now. Maybe try clearing your cache.
 
  • #105
Fredrik said:
The first "here" is displayed as "he re".

As far as I can tell this is vBulletin problem (feature). It splits long text inserting spaces after every 50 characters:

01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789

If you try to quote my post, there are no spaces between digits, they are added to the displayed text only. Unfortunately, MathJax works not with the original post text, but with whatever vBulletin displays.

This way forum formatting doesn't break, but sometimes it means other problems (like in this case).
 
  • #106
Greg Bernhardt said:
I recently forced FF to use HTML instead of MathML. It looks much better to me in FF now. Maybe try clearing your cache.
Many things have improved. Things don't get messed up when I put my mouse over math expressions. The extra space that was displayed next to the phi in \|\phi\|=\|x_0\| is gone. Etc. Math looks OK in Firefox, so I'm not saying that it absolutely must be fixed, but it still doesn't look as good as it does in IE. (I tried clearing the cache. No difference. But perhaps the change you're talking about explains the other improvements that I had already observed).

Borek said:
As far as I can tell this is vBulletin problem (feature). It splits long text inserting spaces after every 50 characters:
Ah, this make sense. Maybe I should be asking why we didn't have this problem before. I see that code tags override this behavior. I hope it's possible to get tex and itex tags to do the same.

Code:
01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
 
  • #107
For me, the rendering of math is really slow now. I am using IE 8.
 
  • #108
This is just to inform that opera mini doesn't render math, all I see is the tex code.

However opera mobile does display the pages correctly although it takes a lot of time (took me almost a minute to load page with some 10 equations).
 
  • #109
mishrashubham said:
This is just to inform that opera mini doesn't render math, all I see is the tex code.

However opera mobile does display the pages correctly although it takes a lot of time (took me almost a minute to load page with some 10 equations).

the mobile skin is not hooked in yet
 
  • #110
DaleSpam said:
For me, the rendering of math is really slow now. I am using IE8.

It is very very slow. I would choose to read garbage threads about UFO than those with ten or so equations!
 
  • #111
samalkhaiat said:
DaleSpam said:
It is very very slow. I would choose to read garbage threads about UFO than those with ten or so equations!

Honestly I think speed is most likely affected by the age of the browser. Recent browser versions of Chrome (11,12), FF (4) and even IE (9) have made great advances in the Javascript engine. If you find the math is loading slowly I would urge you to update to a recent version.
 
  • #112
I've used firefox and IE, and for some reason latex isn't converting for me. I only see the tags and what you type.
 
  • #113
gb7nash said:
I've used firefox and IE, and for some reason latex isn't converting for me. I only see the tags and what you type.

do you have JS security settings that are maybe affecting it? any errors reported?
 
  • #114
Greg Bernhardt said:
do you have JS security settings that are maybe affecting it? any errors reported?

Not that I know of. Latex was working for me prior to this week and I didn't change any security settings. No errors either, I just literally see what the user is typing.
 
  • #115
gb7nash said:
Not that I know of. Latex was working for me prior to this week and I didn't change any security settings. No errors either, I just literally see what the user is typing.
This site has switched to different LaTeX software (that's what this thread is about), so what was working a week ago may not be relevant. Check if Javascript is enabled (in your browser settings). Are you using a proxy? (If you're accessing this site from home, the answer is almost always no). Have you tried to just refresh the page?

By the way, I also see exactly what I typed (including the tex tags) when I save a change to a post I made earlier. But it only happens in that particular situation, and a refresh always solves the problem.
 
  • #116
I noticed the latex images changed since a few days. I don't know if it's because I'm using linux (latex looks different in windows with my computer) but I really like the new look.
 
  • #117
Greg Bernhardt said:
the mobile skin is not hooked in yet

I am happy that PF even has a mobile version.
 
  • #118
Greg Bernhardt said:
Honestly I think speed is most likely affected by the age of the browser. Recent browser versions of Chrome (11,12), FF (4) and even IE (9) have made great advances in the Javascript engine. If you find the math is loading slowly I would urge you to update to a recent version.
I can't update. IE 8 is what is mandated by our IT department. They get mad if you install unapproved browsers.

Why did we need to change? I liked the speed and quality of the previous LaTeX engine.
 
  • #119
Looking at it, I have javascript enabled, but when it tries to render it gives a little message "Loading Web-Fonts Tex/Main/Regular" and then "Web-Fonts not available -- using image fonts instead". The attempt to load the webfonts takes a long time and then the image fonts also takes a long time. Any tips on enabling Web-Fonts?

EDIT: I found it, under security settings. It is still slow, but only annoyingly slow instead of painfully slow.

EDIT2: Actually, it can still be painfully slow. This page took 2 minutes 16 seconds to load: https://www.physicsforums.com/showthread.php?t=337236&page=23
 
Last edited:
  • #120
DaleSpam said:
Why did we need to change? I liked the speed and quality of the previous LaTeX engine.

1. PF hosts nearly 1.3 million latex images
2. Several thousand and counting are hotlinked across the web
3. The old image processor is hard on the server
4. The old image processor is unsupported (chroot is busy)
5. Broken in preview
6. Not available in PMs
7. Limited in blogs and is actually a spin off program

I have just made a tweak to help speed up IE8 viewing. Please update here again on your experience. Thanks!
 
  • #122
Now I don't get any math at all in IE9. (Not really a problem for me, since I use Firefox). It worked yesterday.
 
  • #123
Fredrik said:
Now I don't get any math at all in IE9. (Not really a problem for me, since I use Firefox). It worked yesterday.

Confirmed.

I added this to help IE8, but it seems to break IE9
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7">
 
  • #124
I love firefox but this makes me think we should have a PFfox browser. :biggrin:

You need a new project don't you Greg? :devil:
 
  • #125
I have serious problem with the Latex only starting in the last two days. What do I have to do? Get the Exporor 8 or what?
 
  • #126
yungman said:
I have serious problem with the Latex only starting in the last two days. What do I have to do? Get the Exporor 8 or what?
Internet Explorer 8 appears to be the version that has the biggest problems. LaTeX is working very well in Firefox 4 and Internet Explorer 9. (It looks a bit prettier in IE9, but FF4 is faster, so I still prefer FF4). What browser and what version are you using? If you're using an older version of IE, you should upgrade anyway, not just to get this forum to work better. Most people who have tried Firefox never go back to IE, so you might want to try that.

By the way (this comment is just a contribution to the general discussion in this thread), Internet Explorer 9 automatically scales all math to 120% by default. I think this makes the math too big, expecially when there's normal text on the same line (i.e. when we use itex tags). I think 100% looks better.
 
Last edited:
  • #127
Fredrik said:
Internet Explorer 8 appears to be the version that has the biggest problems. LaTeX is working very well in Firefox 4 and Internet Explorer 9. (It looks a bit prettier in IE9, but FF4 is faster, so I still prefer FF4). What browser and what version are you using? If you're using an older version of IE, you should upgrade anyway, not just to get this forum to work better. Most people who have tried Firefox never go back to IE, so you might want to try that.

By the way (this comment is just a contribution to the general discussion in this thread), Internet Explorer 9 automatically scales all math to 120% by default. I think this makes the math too big, expecially when there's normal text on the same line (i.e. when we use itex tags). I think 100% looks better.

Thanks for the reply. I have XP and I cannot get Exporer 9.

Where to get Firefox? What website is the real one. I don't want to blindly go on the web and get the first one calling themselves Firefox.

I found this one:

http://www.mozilla.com/en-US/firefox/fx/

Is this the one?

Thanks

Alan
 
  • #128
Yes, that's the one.
 
  • #129
height

if i opened a thread with a lot of latex, i used to be able to read the latest post even though the latex in previous posts was still loading

but now the latex takes up so much extra height that if i do this, the latest post gets continually pushed off the screen so fast that i can't concentrate on reading it

there was no problem previously because the full latex used roughly the same height as the "pre-latex", but now it's much taller

also the server now insists on starting a new line even for one letter

is it possible to reduce the height (i think it's too large anyway), or to stop a new line starting each time?​

(i'm using safari 4.1.3)​
 
  • #130


tiny-tim said:
also the server now insists on starting a new line even for one letter

is it possible to reduce the height (i think it's too large anyway), or to stop a new line starting each time?​

(i'm using safari 4.1.3)​


I think the thing about starting a new line for every tex equation might have been covered in posts 84 through 90 of this thread.

I think you can change the size of the equations by right clicking to get a menu with MathJax options.
 
  • #131
height

cepheid said:
I think you can change the size of the equations by right clicking to get a menu with MathJax options.

oooh, i didn't notice that! :biggrin:

if i right-click, i can choose "Settings" and then "Scale all Math …",

which gives me a box headed "Scale all mathematics (compared to surrounding text) by" which was originally set to 125%

i've re-set it to 100%, which i hope will solve the problem o:)

thanks cepheid! :smile:
 
  • #132
Well I paid good money for Mathtype to be able to post equations in LaTex, since I do not speak LaTex.

It does not offer MathJax (whatever that is - I can't find any useful information just lots of journalistic hype)

These new changes mean I can neither view nor post maths now.

I don't view this as a step forward, just another fashion.

Those of us who have seen computers programmed with cogs, switches, punched holes, mag tape, logic chips etc all the way up to modern processors

and languages that come and go

Cobol, Fortran, ADA, PL1, Basic, Pascal, DOS, Unix, C , Perl, Python...

And applications that come and go

Dbase, Wordperfect, Wordstar, ...

are bound to get a bit punch drunk and glassy eyed after a while.
 
  • #133
Studiot said:
Well I paid good money for Mathtype to be able to post equations in LaTex, since I do not speak LaTex.

It does not offer MathJax (whatever that is - I can't find any useful information just lots of journalistic hype)
What are you talking about? MathJax is just the software that translates the LaTeX to an image. You don't have to do anything different from before, except that you no longer have to refresh after each preview.

Studiot said:
These new changes mean I can neither view nor post maths now.
You can definitely post math now, if you could before. What do you mean you're not able to view it?

Studiot said:
I don't view this as a step forward, just another fashion.
This has solved real problems. They're listed in one of Greg's posts above.

Studiot said:
and languages that come and go

Cobol, Fortran, ADA, PL1, Basic, Pascal, DOS, Unix, C , Perl, Python...

And applications that come and go

Dbase, Wordperfect, Wordstar, ...
If you've done all that, you shouldn't find LaTeX very challenging. It's extremely easy to get started, and you can improve your knowledge just by, once in a while, when you see a post that makes you think "I wonder how he did that", click the quote button and read the code.
 
  • #134
Studiot said:
Well I paid good money for Mathtype to be able to post equations in LaTex, since I do not speak LaTex.

It does not offer MathJax (whatever that is - I can't find any useful information just lots of journalistic hype)

Nothing have changed when posting, only displaying is different. MathJax is just a technology to display LaTeX math on the screen. As explained earlier if it doesn't display, that most likely means browser problems.

These new changes mean I can neither view nor post maths now.

Even if you can't see the math, if you post it the way you did before, it should be displayed correctly for others. You can't check it though.

I don't view this as a step forward, just another fashion.

Idea behind the change was not to become more fashionable, but to reduce server load.

Edit: Fredrik was faster. Don't chat while posting.
 
  • #135
Wow, that Firefox 4 do magic, I am back to business!
 
  • #136
yungman said:
Wow, that Firefox 4 do magic, I am back to business!

It is very friendly. I just love it. I've had zero problems with it and the latex looks great.
 
  • #137
Greg Bernhardt said:
Shouldn't have to do this, they are loaded from the mathjax server.
http://www.mathjax.org/help/fonts/" even though you don't have to.
 
Last edited by a moderator:
  • #138
Hm, the fonts that you can download are version 1.0, and the STIX Fonts website says that version 1.2 will have LaTeX support.

I have no idea if this is relevant to the IE8 problems, but I opened the release notes and found this under "known issues":

STIX Fonts release 1.0 should work correctly with Internet Explorer 8 in standards mode. Web site developers who wish to support IE8 should set the document mode by specifying the mode meta tag; see http://msdn.microsoft.com/en-us/library/cc288472(VS.85).aspx#tools for more information. There are known problems with using these fonts not in IE8 standards mode or with earlier versions of IE.​

Edit: I installed them, and I don't see a difference. The math still looks slightly smaller and slightly uglier in FF4 than in IE9 (not so much that it's a problem), and I don't know if it's any faster. It was already pretty fast, so I think this is only worth doing if you're having some sort of problem that you think this might solve.
 
Last edited:
  • #139
Here's how the same equation renders on Windows XP for various browser and font combinations:

[PLAIN]http://hirano.fastmail.fm/PC.png


And on a Mac running 10.6:

[PLAIN]http://hirano.fastmail.fm/Mac.png


I used Firefox 4.0.1 on both systems, and Safari was version 5.0.5.
 
Last edited by a moderator:
  • #140
Is there a way to get it so I can view the actual latex using IE7?

I'm seeing nothing but the tex code similar to others who've posted in this thread.
 
  • #142
Thank you, vela for offering a glimmer of hope.

The (error) messages in my browser clearly indicate that the browser is being redirected to MathJax .org to obtain some file but is unable to succeed.

I do not know if this is because of some security setting in my browser or some other reason and have already started another thread about this.

https://www.physicsforums.com/showthread.php?t=499913

Another thing is also clear, a significant number of other users are also experienceing difficulties.

In these circumstances can someone post the required settings for the benefit of all in difficulty?
 
  • #143
Hail mighty Nebuchadnezza! :smile:
Nebuchadnezza said:
In this thread https://www.physicsforums.com/showthread.php?t=490052

About 1/3rd of the latex is now corrupt. Could anyone have a look at it? It worked before the change.

You keep putting unnecessary {} into your latex.

Mathjax apparently doesn't like that, though the old system put up with it! :rolleyes:

For example, your …

I \, = \, \int {\frac{1}{{x\ln x}} dx

I \, = \, \int\limits_{\frac{\pi }{6}}^{\frac{\pi }{3}} {\sin {{\left( x \right)}^2} dx

should be …

I \, = \, \int \frac{1}{{x\ln x}} dx

I \, = \, \int{\frac{\pi }{6}}^{\frac{\pi }{3}} \sin \left( x \right)^2 dx​

giving …

I \, = \, \int \frac{1}{{x\ln x}} dx

I \, = \, \int_{\frac{\pi }{6}}^{\frac{\pi }{3}} \sin \left( x \right)^2 dx

:wink:
 
  • #144
Well firstly thanks for the help. For the second I can't edit my posts and change it, secondly it worked beforehand.

I think it should continue to work. When i am lazy I just copy/paste from MathType which likes putting in extra parentheses.

Therfore it seems I manually have to edit out every extra parenthesis. Which is to say very tedious when you are working with allot of code =)

Hopefully this gets fixed soon
 
  • #145
The Web Fonts thing gave me a bit of a scare when I first hit it.

I'm using Chrome 13 (dev) with Windows Vista and the first I knew about the change recently was when my laptop locked up for two or three minutes with a message in the bottom left corner about loading TeX fonts. There was no mouse pointer and pressing any key just caused a "beep" so I thought Chrome had crashed Windows and I was going to need to reboot. However, I left it for a few more minutes and when I came back it had recovered.

The results look good to me, better than the images.
 
  • #146
I didn't check all the broken integrals, but the ones I did check don't just have unnecessary {} pairs. They don't have a matching number of { and } symbols. For example,

I \, = \, \int {\frac{1}{{x\ln x}} dx

has four { and three }. I tried it in a LaTeX document, and it doesn't work there. If it worked here before, that was due to a bug.

If this is a still active thread, or one that you like to link to often, then I suppose you can use the reply button to ask a mentor to change it for you. (But I suspect that they wouldn't like it if everyone does that).
 
  • #147
jhae2.718 said:
You should use a better browser. :wink:

I'm using Chrome and on my laptop with Windows 7 on it the browser (actually, the whole computer) still freezes for 10-20 seconds while the javascript math code loads. It seems to only need to do this once per browser session, and all the math displays fine, but it is somewhat annoying.

Strangely, my older laptop with windows xp on it doesn't freeze.
 
  • #148
Fredrik said:
STIX Fonts release 1.0 should work correctly with Internet Explorer 8 in standards mode. Web site developers who wish to support IE8 should set the document mode by specifying the mode meta tag; see http://msdn.microsoft.com/en-us/library/cc288472(VS.85).aspx#tools for more information. There are known problems with using these fonts not in IE8 standards mode or with earlier versions of IE.​

I tried that last night but it broke IE9. I have now added a conditional. Can anyone report if IE8 is better now?
 
  • #149
I have occasional problem with MathJax under Opera :frown: Now and then when reloading PF Opera stops displaying message "Completed request to cdn.mathjax.org", sometimes it gets a step further and displays a message "Completed request to api.vigilink.com". LaTeX is not rendered, when I press escape I get a messgae from MathJax:

MathJax no longer loads a default configuration file; you must specify such files explicitly. This page seems to use the older default config/MathJax.js file, and so needs to be updated. This is explained further at

http://www.mathjax.org/help/configuration

This doesn't happen always, and I guess it is possible that the MathJax error message is misleading.

Chrome and FF work OK though.

Edit: reset helped.

Edit 2: I just realized I didn't test Chrome nor FF as extensively as Opera, so it is quite possible statement that they work OK is too far fetched - for most of the time Opera works OK as well.
 
Last edited by a moderator:
  • #150
Jonathan Scott said:
The Web Fonts thing gave me a bit of a scare when I first hit it.

I'm using Chrome 13 (dev) with Windows Vista and the first I knew about the change recently was when my laptop locked up for two or three minutes with a message in the bottom left corner about loading TeX fonts. There was no mouse pointer and pressing any key just caused a "beep" so I thought Chrome had crashed Windows and I was going to need to reboot. However, I left it for a few more minutes and when I came back it had recovered.

The results look good to me, better than the images.

I have the same problem with Chrome with Vista [on two computers]. Everything just hanged for a minute or so and I couldn't do anything.
 

Similar threads

Replies
3
Views
4K
Replies
15
Views
25K
Replies
4
Views
4K
Replies
8
Views
2K
Replies
3
Views
2K
Replies
4
Views
4K
Replies
3
Views
2K
Replies
3
Views
13K
Back
Top