Jump to content


New extension installed: Syntax highlighting


No replies to this topic

#1 CodeCat

    It's a trap!

  • Gold Member
  • 6111 posts

Posted 09 September 2009 - 13:20

I've installed a syntax highlighting extension onto the wiki. Usage is like a <pre> block, except that it highlights the keywords and symbols that are part of the language, making them easier to pick out. It supports a whole bunch of languages, and you must explicitly specify which language is being used (highlighting C++ code as HTML for example would be stupid, after all).

Usage is as follows:

<source lang=&#34;xxxxx&#34;>
&#40;code to be highlighted&#41;
</source>


Where xxxxx is the language code. Most useful are probably c, cpp, java, php, html4strict, javascript, ini (great for the Generals modding manual!). See the Syntax highlighting extension manual for more details.
CodeCat

Posted Image
Posted Image

Go dtiomsaítear do chód gan earráidí, is go gcríochnaítear do chláir go réidh. -Old Irish proverb



1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users