Extension:InteractiveTimeline

The InteractiveTimeline extension allows users to insert timelines into wiki pages. The timelines are shown using the CHAP Timeline javascript library developed by Almende, so they may be panned and zoomed by the user, and events in the timeline may contain images, links to other wiki pages or sites, and other formatting.

This extension is similar to the ChapTimeline extension, however it provides more parameters to control the displayed timeline, and it does not require Semantic MediaWiki to work.

Installation
This extension is not currently available via the standard MediaWiki extension distributor. To install the extension, you should clone the Git repository into your extensions directory as shown here:

Note that the submodule update is important: that will fetch the CHAP Links Library, of which Timeline is a part.

Once you have cloned the repository, add the following code at the bottom of your LocalSettings.php:

Usage
Once installed, you can place  tags in pages where you want to show a timeline. A large number of parameters may be set in the &lt;itimeline&gt; tag, but all of them are optional. The contents of the tag should be a series of events, with one event defined per line. For example:

Dates and times
All dates and times specified in an &lt;itimeline&gt; tag, whether as a value provided for a parameter, or as part of an event definition, should be formatted using a profile of ISO 8601. The dates and times accepted by InteractiveTimeline should take the form of a calendar date, optionally followed by a time:


 * Dates should be specified as a four digit year (the year including the century), followed by a two digit month (01 to 12), followed by a two digit day (01 to 31), with the sections optionally separated by hyphens. The form of the date should be  or , for example:   or.
 * If a time is not specified, the default of "00:00:00Z" (midnight UTC) is used for the time.
 * If a time is specified, it must be separated from the date by a single space or the letter 'T'.
 * When provided, times should be specified as a two digit hour (00 to 23 ), followed by a two digit minute (00 to 59), followed by a two digit second (00 to 59), with the fields optionally separated by colons. The time should be of the form  or  . The minutes and seconds are optional, and if not specified they default to "00". Decimal fractions are not supported for the time fields. Times must be followed by a time zone designator.
 * The time zone designator should either be "Z" to indicate that the time is in UTC, or it can be an offset from UTC specified as a positive or negative hours (and optionally minutes) of the form ±[HH]:[MM], ±[HH][MM], or ±[HH].

For example, the following dates and times are valid:


 * (5:10pm UTC on the 12th of July 2014)
 * (00:00 UTC on the 14th of August 2014)
 * (13:12:10 in Central Daylight Time on the 12th of July 2014)
 * (8:24am in Central European Summer Time on the 14th of August 2014)

The following parts of ISO 8601 are not supported by InteractiveTimeline:


 * 'Reduced precision' dates (YYYY year only, or YYYY-MM year and month); only complete calendar dates are supported.
 * Week dates
 * Ordinal dates
 * Decimal fractions for hours, minutes, or seconds.
 * Optional time zone designator (the time zone designator must be specified if a time is given)
 * Durations
 * Intervals may only be specified as &lt;start&gt;/&lt;end&gt; as durations are not supported.
 * Repeating intervals.

Parameters
The following parameters may be specified in the &lt;itimeline&gt; tag. All parameters are optional, and if not specified the default is used.

Event Syntax
Inside the &lt;itimeline&gt; tag you define the list of events to show in the timeline. You should include one event per line, and events may not span multiple lines. Events are defined using:


 * &lt;datetime&gt;|&lt;event text&gt;
 * This format defines an event by giving the time of the event and some text describing the event.


 * &lt;datetime&gt;/&lt;datetime&gt;|&lt;event text&gt;
 * This format defines a range using an IS8601 interval. The first datetime is the date and time at which the range starts, the second is the end date and time (inclusive).

'datetime' values should be provided in the format discussed above in the Dates and times section. The event text may contain wiki text, so you may include images, links, or other formatting. Please note that complex wiki text should be avoided, or you will probably make the Timeline display go wonky.

The order in which events are defined is not important, and if the extension can not validate the definition of an event, it will be ignored.

The body of the &lt;itimeline&gt; tag supports transclusion and template expansion, so you may define a list of events elsewhere and transclude them into the body of the &lt;itimeline&gt; tag.

Demo
A publicly accessible MediaWiki demo of this extension is not currently available. The Timeline documentation contains a number of examples of the capabilities of the Timeline library.