Adds GeSHi code highlighting to PHP Markdown.
Latest commit 9f2e6b1 Jul 18, 2011 @drm added gist parameter



A simple extension to the PHP Markdown implementation to add code highlighting to the wordpress plugin using GeSHi.


  • Install the PHP Markdown plugin
  • Install the wp-syntax plugin
  • Download the markdown-geshi.php file in your plugin folder
  • Enable all three plugins and you're good to go


The highlighter is triggered by adding a 'shebang' to the code block. The shebang follows the following syntax:

code to be highlighted

lang is a language to use for highlighting and 123 is a line number to start the numbering with.


    echo "Infinite time...!";

Would render the code starting at while and starting with line number 12.

The line number is optional. If omitted, the lines will not be numbered.

If the shebang is omitted, the standard code block handler from the Markdown_Parser class is used.


If you have any trouble using the plugin, please report an issue at