Jump to content

Syntax Highlighting In Mediawiki


Recommended Posts

Hello everybody,

 

I just installed Mediawiki 1.26 on my brand new stevie and nearly everythings fine. The only thing is that I do not get the syntax highlighting working. I did like I was told here (https://www.mediawiki.org/wiki/Extension:SyntaxHighlight):

 

- Downloaded the files, unzipped them and put them in the extensions/SyntaxHighlight_GeSHi in my wiki folder (already existed, renamed it and replaces it by the new one)

- Added wfLoadExtension( 'SyntaxHighlight_GeSHi' ); at the end of my localsettings.php

-Tried:

 

<syntaxhighlight lang="python" line="1" >

def quickSort(arr): less = [] pivotList = [] more = [] if len(arr) <= 1: return arr else: pass</syntaxhighlight>

But all he does is telling my that this article is under the category: Articles with syntax highlighting error.

 

I would appreciate any help!

 

Thanks Rudi!

Link to comment
Share on other sites

The only other user I know of who both uses it and posts here is paladox2014, one of our regular users. Haven't seen him around lately though...

 

Based on this: https://www.mediawiki.org/wiki/Manual:Installation_requirements

 

Mediawiki should (mostly) work...it's the things that need either SSH (maintenance scripts/upgrades) or special server features that are incompatible. We meet the requirements for the main functionality. We do not provide any of the optional items except for ImageMagick and sendmail. Also, the VisualEditor and Scribunto extensions for MediaWiki are not supported.

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

Thanks Wolstech,

 

paladox2014 could actually hepl me. If anyone wants to use Syntax Highlighting in Mediawiki: Download geshi (https://sourceforge.net/projects/geshi/), place it on your webspace and then just do as you are told here: https://www.mediawiki.org/wiki/Extension:Code/de. That is an older way of Syntax Highlighting that comes without Python and works just fine.

 

Regards

seruemme1204

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...