Template:Modname
Jump to navigation
Jump to search
Documentation The documentation below is transcluded from Template:Modname/doc. (edit | history)
[purge]
A template for setting or getting a mod name.
Usage
{{ modname | set/mainpageset/get/strip/extract/getforfile | <supplemental data, depending on $1> }}
- First unnamed parameter
Value | Description | Example code | Example result |
---|---|---|---|
set |
Set a mod name. This is automatically called by {{mod sub-page}} (which should be transcluded on every page) with the correct mod name for the current page.
|
{{modname|set|Orchid Mod}} |
|
mainpageset |
Automatically set the correct mod name on the main page of a mod. This is because {{mod sub-page}} is not transcluded on the main page of a mod.
|
{{modname|mainpageset}} |
|
get |
Return the previously set mod name. | {{modname|get}} |
Orchid Mod |
strip |
Remove the mod name from a page name. Defaults to the current page name if the second unnamed parameter is omitted. | {{modname|strip|Orchid Mod/Terra Scepter/Crafting tree}} |
Terra Scepter/Crafting tree |
extract |
Extract the mod name from a page name. | {{modname|extract|Orchid Mod/Terra Scepter/Crafting tree}} |
Orchid Mod |
getforfile |
Return a mod name (the previously set one if none is provided), normalized to fit the file naming guidelines for unreleased mods. Usually only useful in other templates. | {{modname|getforfile}} {{modname|getforfile|User:3.145.15.205/MyMod}} |
Orchid Mod User-3.145.15.205-MyMod |