|
|
(32 intermediate revisions by 3 users not shown) |
Line 1: |
Line 1: |
| <noinclude>{{Template}}{{DISPLAYTITLE:Template:file}} | | <noinclude> |
| The contents of a file.
| | {{Template}} |
| {{META Pipe Character}}
| |
|
| |
|
| == Usage == | | ==About== |
| | A ''warning'' box used to report potential danger. |
|
| |
|
| <nowiki>{{file|filename|language|contents}}</nowiki>
| | ==Usage== |
| | Documentation |
| | {{ic|<nowiki>{{Warning|This text should be heeded.}}</nowiki>}} |
|
| |
|
| See documentation about <code><syntaxhighlight></code> for supported languages.
| | ==Example== |
|
| |
|
| <nowiki>{{file|default.nix|nix|<nowiki>
| | {{Warning|This text should be heeded.}} |
| {...}
| |
| {
| |
| # Comment
| |
| }
| |
| </nowiki>}}</nowiki>
| |
|
| |
|
| == Example ==
| | </noinclude><includeonly>{{META Box Red|Warning:|{{{text|{{{1|{{META Error}}}}}}}}}}</includeonly><noinclude>{{Documentation}} |
| | | </noinclude> |
| <nowiki>{{file|main.c|c|
| |
| #include <stdio.h>
| |
| | |
| main( )
| |
| {
| |
| printf("hello, world\n");
| |
| }
| |
| }}</nowiki>
| |
| | |
| <hr />
| |
| {{sandbox|main.c|c|
| |
| #include <stdio.h>
| |
| | |
| main( )
| |
| {
| |
| printf("hello, world\n");
| |
| }
| |
| }}
| |
| <hr />
| |
| | |
| </noinclude><includeonly> | |
| {{#tag:pre|{{{filename|{{{1|{{META Error}}}}}}}} | |
| |style=margin-bottom: 0; border-bottom:none; padding-bottom:1.6em; padding-left:2.7em; margin-top: 0;
| |
| }}{{#tag:syntaxhighlight|{{{contents|{{{3|{{META Error}}}}}}}} | |
| |lang={{{lang|{{{2| }}}}}}
| |
| |style=margin-top: -1em;}}
| |
| </includeonly> | |