Template:FormattingError/doc

From PathfinderWiki

{{FormattingError}} is a utility template designed to be called from other templates.

Example

{{#ifeq:{{NAMESPACE}}|{{ns:0}}|{{FormattingError|Template:xt is only for examples of style and formatting. Do not use it in actual articles.}}

The above code, which is used in the {{xt}} template, raises an error if the template is used in the main article namespace. In other words, if the NAMESPACE's unique numeric code equals 0, produce the given error message.

Because {{xt}} is not to be used in article content, this code allows the template to notify an editor who attempts to do so, instead of displaying the template's contents. This isn't the only way this template can be used, but is a good example of an appropriate use.

Usage

The first parameter passed to the template replaces the generic "Formatting error!" message.