Extension:CrossReference

Description
CrossReference is an extension to create automatically numbered cross references on a wiki page, LaTeX style.

CrossReference provides tags to declare objects as referenced objects: figure, table... Then because these referenced objects have identifiers, they may be referenced somewhere in the text.

Installation

 * 1) Download CrossReference,
 * 2) Unpack the archive in your Mediawiki directory
 * 3) add require_once('extensions/CrossReference/CrossReference.php'); in your LocalSettings.php.

Declare Referenced Objects
A referenced object is an object which has an identifier, and may have a caption.

Several types of referenced objects are supported:
 * : a figure,
 * : a table,
 * : an equation,
 * : a theorem,
 * : a definition, and
 * : a bibliographical reference.

Each of these types have a dedicated HTML tag to declare an object instance, except for the bibliography which is not supported by this extension:

In the text describing the referenced object, the tag &lt;caption/&gt; may enclose the caption of the object. This caption will be render near the referencing object and will appear in all the references in the text.

Example: gives: 

Add Reference in Text
Somewhere on the page, you can put the following to reference the element: where identifier is the code of the referenced object to reference. The given text is put back in the reference hyper link. If this text is not given, the default text is used (basically the object number).

Example: gives: "Figure [#label-fib:myobject 1]".

&lt;xrlabel/&gt;
All the referenced object declarations are wrappers to the tag. This tag supports several parameters:
 * : the identifier of the referenced object;
 * : the type of the referenced object, one of the types describes before;
 * : if present, display the object number between parenthesis (for backward compatibility with the original CrossReference extension);
 * : if present, do not output the HTML tags which are dedicated to referenced objects;
 * : if present, do not apply default caption formatter on the given caption.

&lt;xr/&gt;
Tag &lt;xr/&gt; takes parameters:
 * : the identifier of the referenced object;
 * : if present, do not output the hyperlink.