Template:CodeBox
{{{2}}}
Used to encase programming examples, with extra information attached, like a URL to run the code on a external page.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Language Style | 1 langstyle | The style to use for the internal <syntaxhighlight> block. See https://github.com/wikimedia/mediawiki-extensions-SyntaxHighlight_GeSHi/blob/master/SyntaxHighlight.lexers.php for supported styles.
| String | required |
Code | 2 code | The code contained in this CodeBox
| String | required |
Style | style | Style for the top-level div. | Unknown | optional |
Error Message | erroring | An error message to associate with this Code Box. Will change the style of the header. Only use if the linked code is erroneous in some way.
| String | optional |
Language Name | langname boxtitle | Name of the language in the codebox. User facing name. | String | suggested |
Tryit URL | tryiturl | Contains a URL pointing to a online REPL or similar, to allow the user to "Try out" the code in the box. | URL | suggested |
Tryit Name | tryitname | Name of the site the user will be sent to to run/edit the code on.
| Unknown | suggested |