How to use the syntax highlighter to highlight code in postings

my little forum uses GeSHi as syntax highlighter (example). To enable it you just need to set syntax_highlighter to 1 (BB Code has to be enabled, too) in the advanced settings (Admin -–> Settings -–> Advanced settings).

Code in postings can then be highlightet with the BB Code [code=language]...[/code]. Some common web related languages (CSS, HTML, JavaScript, Perl, PHP, SQL, XML) are already installed but GeSHi can highlight many more languages. If you want to use for example C, download GeSHi and copy the file geshi/c.php into /modules/geshi/geshi/c.php. You can then use the BB Code [code=c]...[/code].

Last modified: 26.07.2008, 23:26  

Contact