Extension:Winter

Winter (Wiki Interpreter) is an extension which adds an interpreted language to Mediawiki pages. It is intended to enhance the templating system but can be used on any page.

Features
Features of the Winter language include:
 * simple syntax
 * variables
 * if/then/else conditional
 * for and while loop conditionals
 * definable functions
 * simple arithmetic
 * simple string manipulation

Download

 * Winter 1.5.0 - Added 03:04, 12 January 2006 (UTC)
 * Winter 1.4.1 - Added 11:55, 2 January 2006 (UTC)
 * Winter 1.4.0 - Added 10:32, 2 January 2006 (UTC)
 * Winter 1.3 - Added 10:25, 6 December 2005 (UTC)
 * Winter 1.2 - Added 19:23, 23 November 2005 (UTC)
 * Winter 1.1 - Added 05:06, 18 November 2005 (UTC)
 * Winter 1.0 - Added 09:04, 16 November 2005 (UTC)

Language specification
Language Specification

Example 1
This example demonstrates the use of defined functions, for loops, and variable assignment

Will return . foobar1 .. foobar2 .. foobar3 .. foobar4 .. foobar5.

Example 2
Template parameters can be accessed easily

Using the code above in a template will return First parameter is set to:param1 if the template is called with a first paramter set to param1 (eg  param1 ). If the first parameter is blank or not used, the template would return nothing.

Example 3 - Creating a Calendar
This example is too large to include on this page.

View Example 3

v1.5.0

 * Added new shortcut syntax:  is the same as .  Each span of whitespace is converted to a pipe character.  This is especially useful for math operations:   =
 * #op can now accept any amount of operations. However, the order of operations is only left to right.   ie  will return 0 and not 4.
 * Added #formula command
 * Added #eval command
 * Added #repeat command
 * fixed some bugs in #strpos

v1.4.1

 * &lt;nowinter> tag added to replace #noeval command

v1.4.0

 * Added #noeval command to allow Winter code to be displayed without being evaluated.
 * Reworked escape character code. Escape characters are now only translated inside of a Winter command instead of anywhere on the page.  This ensures that users who are unaware Winter is installed are not confused.
 * #define actually works now.
 * Switched to x.y.z version numbering system.

v1.3

 * Fixed problems with certain commands inside of a for loop. Also fixed the problem with newlines in variable values.
 * Added mod (modulus) operator.

v1.2
and are now equivalent, as are  and  (an all other operators), assuming a has already been defined by a #setvar or #var command.
 * Introduced new shortcut syntax for variables:

v1.1

 * Fixed a few bugs
 * Nesting didn't always work right depending on syntax
 * != didn't work

v1.0

 * Original Public release

Updates by RSS
Winter updates are published on my blog.

RSS Feed