Skip to content
Github mirror of MediaWiki extension Math - our actual code is hosted with Gerrit (please see https://www.mediawiki.org/wiki/Developer_access for contributing)
Branch: master
Clone or download
translatewiki Localisation updates from https://translatewiki.net.
Change-Id: Ic69ba0710d1563a6cffba77480de0c8912f9b1fd
Latest commit 183fd5c Mar 19, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
db
i18n Localisation updates from https://translatewiki.net. Mar 18, 2019
images
maintenance
mathoid Separate Mathoid from the Math extension Feb 10, 2014
modules
src
tests
.eslintrc.json
.gitattributes Update to MathJax 2.3 Jan 27, 2014
.gitignore
.gitreview
.phpcs.xml
.stylelintrc.json Use json extension for .stylelintrc Aug 19, 2017
CODE_OF_CONDUCT.md
COPYING Add COPYING Mar 1, 2014
Gruntfile.js eslint: Use in all folders (including tests/selenium) Nov 12, 2018
HISTORY
Math.alias.noTranslate.php Convert all array() syntax to [] Apr 13, 2016
Math.alias.php
Math.php
MathLaTeXML.php build: Updating mediawiki/mediawiki-codesniffer to 24.0.0 Feb 6, 2019
README
RELEASE-NOTES-3.0.0 Add release notes for version 3.0.0 Jul 25, 2015
composer.json
extension.json MathWikidataHook.php -> MathWikibaseHook.php Feb 8, 2019
package.json build: Update 'stylelint-config-wikimedia' to v0.5.0 Jan 9, 2019

README

The version for MediaWiki 1.31+ has some changes since previous versions:

By default the math rendering service from the Wikimedia Foundation located at
https://wikimedia.org/api/rest_v1/
will be used for math rendering.
Therefore php-curl is required.
cf. https://www.mediawiki.org/wiki/Manual:CURL

Consult https://www.mediawiki.org/wiki/Extension:Math for further information and advanced settings.

Attributes of the <math /> element:
attribute "display":
possible values: "inline", "block" or "inline-displaystyle" (default)

"display" reproduces the old texvc behavior:
The equation is rendered with large height operands (texvc used $$ $tex $$ to render)
but the equation printed to the current line of the output and not centered in a new line.
In Wikipedia users use :<math>$tex</math> to move the math element closer to the center.

"inline" renders the equation in with small height operands by adding {\textstyle $tex } to the
users input ($tex). The equation is displayed in the current text line.

"inline-displaystyle" renders the equation in with large height operands centered in a new line by adding
{\displaystyle $tex } to the user input ($tex).

For testing your installation run
php tests/phpunit/phpunit.php extensions/Math/tests/
from your MediaWiki home path.

== Logging ==
The math extension supports PSR-3 logging:
Configuration can be dona via
$wgDebugLogGroups['Math'] = [ 'level' => 'info', 'destination' => '/path/to/file.log' ];
You can’t perform that action at this time.