feed twitter facebook linkedin

SourceCode HighLighter for bbPress

June 12, 2010 on 5:04 pm 2 Comments

Description

SourceCode HighLighter is a plugin developed for bbPress that highlight source code in a message. SourceCode HighLighter is developed usign Generic Syntax Highlighter (GeSHi).

Tags:  code, formatting, syntax highlight

Tested over bbPress version 1.0

Versions

  • SourceCode HighLighter v1.0
    • First version

Install

  • Unzip the plugin archive.
  • Copy sourcecode-highlighter folder into you bbPress plugin directory.
  • Activate the plugin

How use it?

  • Use the PRE tag to highlight the code.
  • Optionally you can use the LANG attribute to indicate the programming language to use as a format.
  • Optionally you can use the LINENO attribute to indicate the line number for which will begin to number the code. See supported sourcecode languages by GesHi.
  • Use single quotes for LANG and LINENO attribute values.

Sample

Just copy&paste this code in a bbPress message:

<pre lang='java' lineno='1'>
public class HolaMundo {
  public static void main(String[] args) {
    System.out.println("Hola Mundo");
  }
}</pre>

Use single quotes for lang and lineno.

Websites that use SourceCode HighLighter

Dudas de Programacion (http://www.dudasprogramacion.com)

Download

Download the lastest version http://code.google.com/p/vcp/downloads/detail?name=sourcecode-highlighter-bbpress.zip

2 Comments »

RSS feed for comments on this post. TrackBack URI

  1. Víctor Cuervo » SourceCode HighLighter un plugin para bbPress
    13 June 2010 #

    [...] El plugin es SourceCode HighLighter. [...]

  2. lfgu
    28 January 2012 #

    Thanks for your wonderful plugin.

    When i active your plugin, i got following error:
    Fatal error: Cannot redeclare class GeSHi in forum/my-plugins/sourcecode-highlighter/geshi.php on line 255

    could you tell me how to fix this error?

    Thanks

Leave a comment

XHTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

*