MediaWiki/Syntax highlighting: Difference between revisions
mNo edit summary |
m Text replacement - "<(\/?)source" to "<$1syntaxhighlight" |
||
| (One intermediate revision by one other user not shown) | |||
| Line 11: | Line 11: | ||
== Usage == | == Usage == | ||
Just use the '''<nowiki>< | Just use the '''<nowiki><syntaxhighlight></nowiki>''' tag with the ''lang'' parameter to define the programming language. Other optional parameters are avaliable too. See the example below. | ||
== Parameters == | == Parameters == | ||
| Line 30: | Line 30: | ||
== Example == | == Example == | ||
< | <syntaxhighlight lang="php" line> | ||
<?php | <?php | ||
if( !defined( 'MEDIAWIKI' ) ) | if( !defined( 'MEDIAWIKI' ) ) | ||
| Line 50: | Line 50: | ||
?> | ?> | ||
</ | </syntaxhighlight> | ||