| Vorlagenprogrammierung | Diskussionen | Lua | Unterseiten | |||
| Modul | Deutsch | English | Modul: | Dokumentation | ||
Vorlage:Handle – Module to generate titled external links to web ressources by solver, transcluded by templates.
Template:Handle might be an abstract concept with two instances to be supported:
1 – show a remark about temporary unavailability1 – suppress general error category defined by errCat this time.1 – suppress any hiding of error messages this time; e.g. for documentation and examples#invoke for project specific adaption; all but scheme optional:
doihdlerror1 – hide error messages by defaultproblemdoi: schema link – default: Digital Object Identifierclass="error".The Failsafe interface is heading for version management of globally distributed Lua modules. It enables modules equipped with this interface to
The Failsafe interface is present both at template level and for direct Lua access.
The functions in detail are (not all supported yet completely by every library):
| Value | Result | current |
|---|---|---|
nothingfalse |
local version ID | »2026-01-29« |
| Minimal version | version ID required at least date in ISO format It will be compared whether the current local implementation matches this version or later.
|
|
wikidata |
version ID of global upstream
|
»2026-01-29« |
item |
ID of the Wikidata item
|
Q19644424 |
~ |
Corresponding version ID locally and registered at Wikidata
|
»« |
@ |
Is the current (module) page linked correctly with Wikidata item?
|
|
The return value is in template programming empty or under Lua false, otherwis a non-empty string as described. | ||
The functions described above can be used by other modules:
local lucky, Handle = pcall( require, "Module:Vorlage:Handle" )
if type( Handle ) == "table" then
Handle = Handle()
else
-- failure; Handle is the error message
return "<span class=\"error\">" .. Handle .. "</span>"
end
Subsequently there are available:
wikidata or ~