Filters: GeSHi

Maintained by Picture of Enovation Dev TeamEnovation Dev Team
Color or highlight code snippets within Moodle resources - filter to be removed, use instead,
237 sites
16 fans
Current versions available: 2

This plugin is obsolete now.

Unfortunately GeSHi library is not maintained, from the website:

The latest stable version of GeSHi is, released on the 19th of Aug, 2012.

So this Moodle filter should be removed. We suggest to use another one - e.g.


This plugin is part of set Seeking new maintainer.


Screenshot #0
Screenshot #1
Screenshot #2
Screenshot #3
Screenshot #4


Picture of Enovation Dev Team
Enovation Dev Team (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS


  • Anthony Borrow
    Wed, Mar 19, 2014, 10:06 AM
    Many thanks for sharing this code with the Moodle community. I was wondering if you might provide some history about this plugin. It looks like it may have started with the code at by Nigel McNie and then it looks like some work was done by David Mudrák at Is Enovation taking the lead on this code?

    Also, please review and provide the source, tracker and documentation URLs. For documentation, might we want to use If so, we should probably update it to match the instructions for usage in the README. If you have a moment, a screenshot would also be helpful.

    For now I am going to mark this as needing more work until we get the URLs worked out and documentation updated.

    I was able to successfully install and use the filter in Moodle 2.6. So once we get things tidied up we should be able to approve this.

    Peace - Anthony

    Peace - Anthony
  • Picture of David Mudrák
    Thu, Mar 27, 2014, 9:23 PM
    Correct, it was agreed between me and Tomasz Muras that Enovation would take the lead on maintaining this filter.

    I am not sure this needs more documentation than the one provided via README at the source control URL (which is added now). The old "Code syntax highlighting" could be improved and updated, for sure. But I do not see it as a blocker for approval, given that the filter works.
  • Picture of David Mudrák
    Thu, Mar 27, 2014, 9:32 PM
    OK, the page as is now is really confusing. Anthony is right - we need it updated before approving this plugin. It would be great if the new maintainers look at it.

    There is no actual code change from the version we use in production already, so the updated docs page would be a good sign that Enovation means it seriously with supporting this filter. Thanks in advance!
  • Anthony Borrow
    Wed, Apr 9, 2014, 10:08 AM
    Thanks for updating the URLs and the documentation. I think all is looking good and will go ahead and approve this. Peace - Anthony
  • Anthony Borrow
    Wed, Apr 9, 2014, 10:09 AM
    It is encouraged to follow Moodle's coding style as outlined in:

    Tthe code checker plugin can be quite helpful in fine tuning your code and can be found at:

    You may wish to consider using that tool to further improve your plugin. Below, are the initial results:

    filter/geshi/lang/en/filter_geshi.php - 2 error(s) and 0 warning(s)
    filter/geshi/version.php - 2 error(s) and 0 warning(s)
    filter/geshi/filter.php - 138 error(s) and 32 warning(s)
    filter/geshi/README.txt - 3 error(s) and 0 warning(s)
  • Picture of David Mudrák
    Tue, May 6, 2014, 6:11 AM
    Please note there is a mismatch between the $plugin->version declared in version.php and the version set in this directory. Please keep them in sync to avoid confusion.
  • Gmads
    Sat, Jul 12, 2014, 2:41 AM
    To add to the confusing and chaotic situation behind Geshi:
  • Picture of nivedita setru
    Mon, Jan 19, 2015, 8:09 PM
    The version number on download link doesn't match with version number within version.php file.
  • Picture of Alexei Barantsev
    Thu, Sep 1, 2016, 2:02 PM
    Is there a 3.1 compatible version?
  • Lina
    Fri, Nov 18, 2016, 4:37 PM
    Hi All,
    We are using the Moodle 3.1.
    I found that the Geshi filter code syntax highlight works fine by adding the "<" "code" ">"tag.
    But for the tag like "<""code css" ">" can only display the highlighting in the label activity or the description. In the activity content's text editor, this tag cannot work. Take the wiki activity as an example, if I put the code ".que .info .grade{display: none;}" into the wiki description and the wiki content, only the wiki description can display the code syntax highlighting. The wiki content text editor will clear the tag automatically and cannot show the highlighting.
    I just think this might be useful to other people, so I tried to share this here.
    Cheers, Lina
  • Picture of Ger Tielemans
    Wed, Mar 22, 2017, 4:52 PM

    Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; GeSHi has a deprecated constructor in: ..\server\moodle\filter\geshi\geshi\geshi.php on line 259
  • Picture of Mikey Ward
    Tue, Oct 17, 2017, 10:44 PM
    We are evaluating Blackboard/Moodle before buying in, and I'm not quite sure of all of the terminology yet. Could this filter be applied to forum posts, say for code-related forum questions by students?
Please login to post comments