Last modified: 2014-02-12 23:32:46 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T50867, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 48867 - Tex code rendering with MathJax not working
Tex code rendering with MathJax not working
Status: RESOLVED INVALID
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.20.x
PC Linux
: Unprioritized normal (vote)
: ---
Assigned To: Nobody - You can work on this!
http://freeplane-up.sourceforge.net/w...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-27 17:12 UTC by frederic.leger
Modified: 2014-02-12 23:32 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description frederic.leger 2013-05-27 17:12:12 UTC
With Mediawiki on sourceforge.net I try to use MathJax 2.2.
After installation on the VPS, the MathJax test is working (http://freeplane-up.sourceforge.net/wiki/MathJax/test/index.html).
But the MathJax does not recognize by mediawiki. 

After setting up LocalSettings.php as example (https://www.mediawiki.org/wiki/Extension:Math) I have an error when mediawiki try to render TEX code.
on Apache : PHP Notice:  Use of undefined constant MW_MATH_MATHJAX - assumed '
MW_MATH_MATHJAX' in /home/project-web/freeplane-up/htdocs/wiki/LocalSettings.php on line 309, referer: http://freeplane-
up.sourceforge.net/wiki/index.php/LaTeX_in_Freeplane

tail of LocalSettings :
$wgUseMathJax = true; // enabeling MathJax as rendering option
$wgDefaultUserOptions['math'] = MW_MATH_MATHJAX; // setting MathJax as default rendering option (optional)
$wgMathJaxUrl = 'http://freeplane-up.sourceforge.net/wiki/MathJax/MathJax.js?config=TeX-AMS_HTML'; // specifying the path to local MathJax in case MathJax's CDN should not be used (optional)
?>

When I do a "grep -i MW_MATH_MATHJAX ..." on wiki and MathJax package this constant is not define other than LocalSettings.php !
Comment 1 Sam Reed (reedy) 2013-05-27 19:02:16 UTC
Based on http://freeplane-up.sourceforge.net/wiki/index.php/Special:Version and your paste above, you don't have the math extension included.

You need to add the following before the maths settings you already have:

require_once("$IP/extensions/Math/Math.php");
Comment 2 frederic.leger 2013-05-28 05:10:38 UTC
I add the Math module, but this one does not exist

>$ ls extensions/
Babel	      Freeplane.php				Nuke		 ReplaceText		    Vector
CleanChanges  Gadgets					ParserFunctions  SpamBlacklist		    VisualMathCaptcha
ConfirmEdit   GeSHiHighlight.php			Piwik		 Translate		    WikiEditor
FCKeditor     INSTALL.MediaWikiLanguageExtensionBundle	README		 TwitterFBLike		    cldr
Freeplane     LocalisationUpdate			Renameuser	 UniversalLanguageSelector  geshi

When I try to reload webpage:
Warning: require_once(/home/project-web/freeplane-up/htdocs/wiki/extensions/Math/Math.php) [function.require-once]: failed to open stream: No such file or directory in /home/project-web/freeplane-up/htdocs/wiki/LocalSettings.php on line 307

Fatal error: require_once() [function.require]: Failed opening required '/home/project-web/freeplane-up/htdocs/wiki/extensions/Math/Math.php' (include_path='/home/project-web/freeplane-up/htdocs/wiki:/home/project-web/freeplane-up/htdocs/wiki/includes:/home/project-web/freeplane-up/htdocs/wiki/languages:.:/usr/share/pear:/usr/share/php') in /home/project-web/freeplane-up/htdocs/wiki/LocalSettings.php on line 307

At http://www.mediawiki.org/wiki/Extension:Math I read "It was a part of the core MediaWiki software until MediaWiki 1.18", what's wrong?
Comment 3 Matthew Flaschen 2013-05-28 05:30:32 UTC
It was part of MediaWiki core, but it no longer is.  In later versions, you need to install the extension, as noted at https://www.mediawiki.org/wiki/Extension:Math (see Download and Installation sections).

This is not a bug in the software.  If you need help installing the Math extension, try emailing mediawiki-l (https://lists.wikimedia.org/mailman/listinfo/mediawiki-l).
Comment 4 frederic.leger 2013-05-28 07:31:13 UTC
Finally texvc can not be compiled in Sourceforge to activate normally Math extension. See "http://www.mediawiki.org/wiki/Manual_talk:Installing_MediaWiki_on_SourceForge.net#Enabling_math_under_Sourceforge.net".
So I close this ticket.
Regards for your help.
Comment 5 Matthew Flaschen 2013-05-28 07:46:30 UTC
You shouldn't need to compile texvc if you're only using MathJax.  That is a very old post from before MathJax was even available.  I wouldn't be surprised if the SourceForge shell options have changed too.

There is also a Debian/Ubuntu package for texvc, mediawiki-math.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links