Anonymous
Not logged in
Talk
Contributions
Log in
Request account
Rest of What I Know
Search
Editing
Template:Semantic markup templates
From Rest of What I Know
Namespaces
Template
Discussion
More
More
Page actions
Read
Edit
History
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{Navbox | name = Semantic markup templates | state = {{{state|{{{1|<includeonly>collapsed</includeonly>}}}}}} | title = {{c|Semantic markup templates}} | liststyle = font-size:110%; | tracking = no <!-- keep the documented templates out of the hlist tracking category --> | list1 = {{Aligned table |cols=3 |class=wikitable sortable |style=line-height:1.35em;text-align:left; |colstyle=<!--vertical-align:middle;-->padding-right:1.0em; |col2style=white-space:nowrap; |col3style=white-space:normal; |row1style=line-height:1.6em; |row1header=on | Template | Example output | Use | {{tlb|strong}} | {{strong|Important!}} | To indicate [[HTML element#strong|<nowiki><strong></nowiki>]] importance, seriousness, or urgency instead of just simple typographical boldfacing | {{tlb|strongbad}} | "{{strongbad|Never}} use ..." | Same as {{braces|strong}} but in red | {{tlb|stronggood}} | "{{stronggood|Only}} use ..." | Same as {{braces|strong}} but in green | {{tlb|em}} | "An {{em|emphatic phrase}}" | To indicate [[HTML element#em|<nowiki><em></nowiki>]] stress emphasis (not just purely typographical italicization like for book titles or foreign terms) | {{tlb|var}} | {{var|strPrefix}} | To indicate text is a variable name. Use for any variable names except those including "I" (uppercase i) and/or "l" (lowercase L); for these, {{braces|var serif}} should be used to ensure a noticeable distinction | {{tlb|var serif}} | {{var serif|strIllustratePrefix}} | (see {{braces|var}} above) | {{tlb|tld}} | {{tld|DEFAULTSORT:Y, X}} | To display wikicode variables and [[Help:Magic words|magic words]] as they would appear in code | {{tlb|para}} | {{para|year|2008}} | To display template parameters with or without values | {{tlb|param}} | {{param|title|alt}} | To display parameters as used in code (i.e. with triple braces), especially to indicate relationships between them. May be combined with {{braces|para}} above | {{tlb|tjp}} | {{tjp|selfref: yes|category: no}} | To display template parameters with colors (as they would appear in the {{tl|tj}} and {{tl|tji}} templates) | {{tlb|param value}}| {{pvalue| 2 blanks fore and aft |space=Β·}} | To display parameter values lightly bordered; replaces <code>...</code>, especially when value contains embedded or leading/trailing blanks; visualized here with [[middot]] (·) but can use β , β―, or any character. | {{tlb|tlx}} etc. | {{tlx|Template|{{var|1}}|{{var|2}}|...|{{var|10}}}} | To display a template call (with or without parameters and values) as code | {{tlb|tji}} | {{tji|hatnote|Hello|selfref: yes|category: no}} | To showcase with colors in horizontal format the syntax of any template, while providing an easy way to display placeholder texts using colons as separators | {{tlb|tag}} | {{resize|95%|"The {{tag|img}} tags ..."}} | To render [[HTML element]]s ("tags") in prose | {{tlb|code}}/{{tlb|codett}} | {{resize|95%|"Ensure the {{code|1=alt=}} parameter ..."}} | To indicate text is source code. To nest other templates within {{braces|code}}, use {{tag|code}}. {{tl|codett}} differs only in styling: {{code|someMethod}} becomes {{codett|someMethod}} | {{tlb|PreCode}} | {{resize|95%|"[[Forth (programming language)|FORTH]] has keyword {{PreCode|?BRANCH}}."}} | Like {{tlb|code}}, but prevents line breaks inside the code. Only for very short code parts. | {{tls|codenowiki}} | <code><nowiki>{{small|small text example}}</nowiki></code> | To wrap example code in {{code|<code><<nowiki>nowiki</nowiki>>...<<nowiki>/nowiki</nowiki>></code>}} | {{tls|kbdnowiki}} | <kbd><nowiki>{{large|large text example}}</nowiki></kbd> | To wrap example code in {{code|<kbd><<nowiki>nowiki</nowiki>>...<<nowiki>/nowiki</nowiki>></kbd>}} | {{tlb|syntaxhighlight}} | <sub>[this is a block template]</sub> | ({{thin space|or {{tlx|sxhl}}}}) Wrapper for {{tag|syntaxhighlight}}, but will wrap overflowing text | {{tlb|deprecated code}} | "Do not use {{tag|{{deprecated code|blink}}|o}}." | ({{thin space|or {{tlx|dc}}}}) To indicate [[Deprecation|deprecated]] source code in template documentation, articles on HTML specs, etc. The {{tlx|dc2}} variant uses strike-through ({{tag|{{dc2|blink}}|o}}) while {{tlx|dcr}} uses red ({{tag|{{dcr|blink}}|o}}). | {{tlb|pre}} | <sub>[this is a block template]</sub> | For larger blocks of source code and other pre-formatted text | {{tlb|tj}} | <sub>[this is a block template]</sub> | To showcase with colors and multiple lines (vertical format) the syntax of any template, while providing an easy way to display placeholder texts using colons as separators | {{tlb|quote}} | <sub>[this is a block template]</sub> | For block quotations (only β never for non-quotations) | {{tlb|block indent}} | <sub>[this is a block template]</sub> | For indented blocks of material; visually identical to {{tlx|quote}} but without quote markup | {{tlb|kbd}} | {{kbd|user input}} | To indicate user input | {{tlb|key press}} | {{key press|Ctrl|x}} | To indicate specific-keystroke input, including combinations | {{tlb|key top}} | {{key top|Left shift}} | Similar; includes more symbols, but does not directly support combinations | {{tlb|button}} | {{button|Don't save}} | To indicate a button in a user interface | {{tlb|samp}} | {{samp|example output}} | To indicate sample or example output }} }}<noinclude>{{documentation}}</noinclude>
Summary:
Please note that all contributions to Rest of What I Know are considered to be released under the Creative Commons Attribution-ShareAlike (see
Rest of What I Know:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Wiki tools
Wiki tools
Special pages
Page tools
Page tools
User page tools
More
What links here
Related changes
Page information
Page logs