Log in to remove this sponsored message
Hey all,
The
Standard Template Package has undergone a rename and an overhaul. It was never in working condition, but I've been working hard on the back-end of things, so we should be ready to roll soon (whenever that is).
NeoWiki Standard Template LibraryWhat is it?The NeoWiki Standard Template Library (STL) is a collection of Templates designed to be used across most or all Wikis, especially new Wikis.
PurposeThe NeoWiki STL is a way to provide a suite of out-of-the-box templates for use on newly created Wikis, as well as allowing editors to use many Templates with identical syntax and functionality across many Wikis without having to add the Templates manually. For example, if "Template:Infobox" is a maintained Standard Template, you could go from one Wiki to another and use it with the exact same syntax and expect to get almost the exact same thing on every Wiki. No worrying about having to add the Template or getting something you didn't expect.
How it worksNote: We previously examined the possibility of using InterWiki Templates, but the whole system was slow and inflexible.
All Templates considered "Standard Templates" will be developed by me. No one else will edit them. The latest version of each Standard Template will be located on neowiki.neo. To
install the STL to a particular Wiki, I will use my special patented bot to copy all Standard Templates from neowiki.neo to the Wiki of choice. If the Wiki has a previous version of the STL installed, I may choose to
update the STL on that Wiki if changes have been made to the original Templates for whatever reason (fixing bugs, adding functionality). When a Template is "updated" from the source Template on neowiki.neo, all code will be overwritten on the destination Wiki's copy of the Template.
It's apparent that some Templates shouldn't necessarily look the same on all Wikis. To accommodate changes, I have implemented an interface where editors may edit how Standard Templates look (or perhaps even behave) on individual Wikis. Any changes made to the Template using this interface will not be overwritten by the bot on STL updates; only the core code will be.
Interface: Special:TemplateSettingsThis special page is what people will use to customize Standard Templates on individual Wikis. To try it out, type in the name of a Customizable Standard Template. Currently, only "MessageBox" and "Stub" work.
What you'll notice right away is that each "setting" (or "option") has a text box showing the current value. That's where you can change it. Once you're done editing the settings, you can click preview to see what the Template would look like with those changes and whatever preview code you specify (for MessageBox, try {{MessageBox|Message text here}}). If you like how it looks, you can click save to make the changes to the Template's source code. The edit will appear in Recent Changes with your name and an auto summary.
By default, all Standard Templates will be protected to prevent editing from normal users, but anybody can make customizations using this interface. If a Template is being abused, then you have the option to "protect" it which will prevent normal users from even usinng the interface to modify it; only Staff/Janitors+ will be able to save changes using the interface, but anybody can play around with previews and such.
There are a bunch of neat features in the interface, but I don't have all day to explain them, so feel free to discover them for yourself. Also, we can eventually add more features, such as a color picker.
Anatomy of a Standard TemplateNot all Standard Templates will be customizable, but for those that are, their makeup is a little different than that of normal Templates. First of all, elsewhere on the Template page, outside the Template's core code, is a list of settings with their names, current values, and default values (before they were changed). When you use the interface, you are essentially editing that little area of the page.
Inside the Template's core code, there is a new <standard_template> tag and a bunch of option placeholders starting with a dollar sign. When the Template is called from a page, the tag looks for placeholders inside the source code and replaces them with settings found on the Template page. An additional feature that the tag introduces is the ability to override any saved settings by using Template parameters of the same name. For instance, to override a setting called "background-color" on a Template, when you call the Template, you can pass a parameter called "background-color" to override the value of what was saved to the Template (e.g., {{TemplateName|background-color=red}}).
Parent Templates & Sub-TemplatesA new feature I'm adding as part of the STL is the incorporation of what I'm calling Parent Templates and Sub-Templates. A Sub-Template is simply a Template whose primary function is using another Template. In such a scenario, the Template being used is referred to as the Parent Template. An example of a Sub-Template is
Template:Stub. All Stub does is call
Template:MessageBox, pass a
text parameter, and modify some settings (colors). When a Template is declared as a Sub-Template (in the source code), if it is also a Standard Template with its own settings, any of the Template's settings may be specified as an asterisk (*), which will cause the Template to inherit the value the Parent Template is currently using. For instance, the background-color option for Template:Stub could be set to "*", so that it would be the same as Template:MessageBox (Stub's parent). If you were to change the option's value on Template:MessageBox, all instances of Template:Stub would reflect the same change.
If you want to create a custom Template that uses the functionality of a Standard Template, you can have your Template simply call the Standard Template and pass parameters to change some of its settings. For instance, if you wanted to create several different-looking Infoboxes on your Wiki, you don't have to write them from scratch, you can have each Template itself just call Template:Infobox and use parameters to change how it looks.
What We Need From YouWe still need to decide what Templates will be a part of the STL. Since you folks will be the ones using the Standard Templates, it's fitting that you would get to pick most of them. Go ahead and post any Templates you'd like to see in the STL. Please include a link to the Template if you have an example. If you have an idea for a Template that hasn't been created yet, feel free to post that too, and I may create it. Keep in mind that a Standard Template should be something that lots of Wikis can make use of--not something that just a few Wikis could use.
Mod Edit: Mar 30, 12 3:02pm by Dragoon