Help:Adding a new programming example: Difference between revisions

→‎Navigation: updated example to new lang tags
m (→‎Navigation: Fixed up a bit, when will we get code highlighting working?)
(→‎Navigation: updated example to new lang tags)
Line 19:
Optional text explaining stuff
<code lang="C" c>
int main ( void ) {
// Some code here
}
</codelang></nowiki>
 
You don't have to use the C programming language, and your code example will probably be different. You need to make sure you create a link to your language of choice, and to your compiler, interpreter, or what-have-you using the "works with" template. You should also note any special [[libraries]] you use with the "libheader" template.
 
The <nowiki><codelang></nowiki> tags enclose the actual example, and allow [[Help:Syntax_highlighting|syntax highlighting]], which includes proper formatting for white space.
 
==Formatting==
973

edits