Questions about this topic? Sign up to ask in the talk tab.

Template:Code

From NetSec
Revision as of 05:27, 12 April 2012 by MinnaBeauvais (Talk | contribs)

Jump to: navigation, search

{{{text}}}

Usage

{{code
   |text=
   your code would go here.
   maybe some here too.
 }}

Would give you:

your code would go here.

maybe some here too.

If you want the code box to have syntax hilighting, use:

<syntaxhighlight lang=""> or <source lang="">

Example:

{{code
|text=
<source lang="cpp">
int exampleFunction(int x, int y){
int Sum = x + y;
return Sum;
}
</source>
}}


Will give you:

 
int exampleFunction(int x, int y){
int Sum = x + y;
return Sum;
}