Template:Code/doc: Difference between revisions
Content added Content deleted
(Created page with "{{doc/start}} To be used if you want to list some short code, which you want to stand out. Similar to using <nowiki><code></code></nowiki> tags, except that it has a grey back...") |
(+TR) |
||
Line 9: | Line 9: | ||
; class= |
; class= |
||
CSS class(es). |
|||
; id= |
; id= |
||
Line 19: | Line 19: | ||
== Examples == |
== Examples == |
||
{{tl|code|lang{{=}}css|border:1px solid #fff}} => results in {{code|lang=css|border:1px solid #fff}} |
{{tl|code|lang{{=}}css|border:1px solid #fff}} => results in {{code|lang=css|border:1px solid #fff}} |
||
Note: Template based off [[wikipedia:Template:Code]] and [[mw:Template:Code]] |
Note: Template based off [[wikipedia:Template:Code]] and [[mw:Template:Code]] |
||
<noinclude> |
|||
[[tr:Şablon:Kod/belge]] |
|||
</noinclude> |
|||
{{doc/end}} |
{{doc/end}} |
Revision as of 07:06, 7 May 2020
Template:Doc/start To be used if you want to list some short code, which you want to stand out. Similar to using <code></code> tags, except that it has a grey background.
Usage
Use {{code|Code to display}}
, which results in
.
Code to display
- Unnamed parameter 1
The code to display.
- class=
CSS class(es).
- id=
Id attribute.
- lang=
The language of code.
Examples
{{code|lang=css|border:1px solid #fff}}
=> results in border:1px solid #fff
Note: Template based off wikipedia:Template:Code and mw:Template:Code