Template:Error/doc: Difference between revisions
From Zoophilia Wiki
Jump to navigationJump to search
meta>Yarnalgo mNo edit summary |
meta>Yarnalgo mNo edit summary |
||
| Line 6: | Line 6: | ||
=== Usage === | === Usage === | ||
* {{tlx|error|An examplary error}} → {{error|An examplary error}} | * {{tlx|error|An examplary error}} → {{error|An examplary error}} | ||
* Compare: <nowiki>{{#expr: | * Compare: <nowiki>{{#expr:Foo}}</nowiki> → {{#expr:Foo}} | ||
* <nowiki>{{#iferror:{{error|Foo}} | {{y}} | {{n}} }}</nowiki> → {{#iferror:{{error|Foo}} | {{y}} | {{n}} }} | * <nowiki>{{#iferror:{{error|Foo}} | {{y}} | {{n}} }}</nowiki> → {{#iferror:{{error|Foo}} | {{y}} | {{n}} }} | ||
Revision as of 06:18, 20 February 2010
| This is a documentation subpage for Template:Error. It may contain usage information, categories and other content that is not part of the original template page. |
Create a parser function error message.
Usage
{{error|An examplary error}}→ An examplary error- Compare: {{#expr:Foo}} → Expression error: Unrecognized word "foo".
- {{#iferror:{{error|Foo}} | {{y}} | {{n}} }} →

The tag to contain the error message can be given through the tag parameter, but it will only accept span, div, p, and strong, since those are the only tags recognized by the #iferror parser function. It defaults to strong, the tag genereated e.g. by #expre.
{{error|An examplary error span|tag=span}}→ An examplary error span
See also