A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://www.mediawiki.org/wiki/Extension:VariablesLua below:

Extension:VariablesLua - MediaWiki

The VariablesLua extension provides support for the Variables extension in Lua modules by the Scribunto extension.

Bugs and Feature Requests
Issues at GitHub

Manual: Liquipedia Help

The extension can be loaded in Lua modules by the Scribunto extension like this:

VariablesLua = mw.ext.VariablesLua

Functions are based on the ones provided by the Variables extension, adding some more utility.

VariablesLua.vardefine[edit]

VariablesLua.vardefine( name, value )

Stores the given value under the given name. An empty string is stored if the value is nil.

VariablesLua.vardefineecho[edit]

VariablesLua.vardefineecho( name, value )

Identical to VariablesLua.vardefine, but returns the value after storing it.

VariablesLua.var( name, default )

Retrieve a variable stored under the given name.

VariablesLua.varexists[edit]

VariablesLua.varexists( name )

Check if a variable exists. Returns a boolean value.

VariablesLua.var_final[edit]

VariablesLua.var_final( name, default )

Returns the last value stored (i.e. the last VariablesLua.vardefine or #vardefine in the code). The value can only be returned and not used in the Lua code.

1.0.0
1.1.0
1.2.0
1.2.1
1.3.0
1.4.0
1.4.1
1.4.2
1.5.0
1.6.0
This extension is included in the following wiki farms/hosts and/or packages: This is not an authoritative list. Some wiki farms/hosts and/or packages may contain this extension even if they are not listed here. Always check with your wiki farms/hosts or bundle to confirm.

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4