MyBB Community Forums

Full Version: MyBB | Python Syntax
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi
Is there a plug-in to colorize Python code?
Note: must comply with mybb 1.8
Thanks.
Up.. help me, please.
I did (for 1.2) GeSHi Mycode plugin, it works with my forum wich is now in 1.8.6.
Just change the compatibility to match your version.
Do you have a coloring Python language?

How will I do?

Thanks but it is not run...

up up up
Up...
Quote:... it is not run ..
can you brief what exactly is not run .. have you tried changing the plugin's compatibility
I did, problem contiunes
^ well, what is actual problem ?
I've done a new version of this plugin.
Dev version (I'll pass it into stable in a couple of weeks) can be found at ABP GeSHi
We had to completely redo the mybb syntax highlighter plugin as its using V3, and is buggy. But V4 is OK. 

https://github.com/syntaxhighlighter/syntaxhighlighter

We created a custom mycode to insert the necessary pre tags calling the python class from version 4. Then we had to replace break lines inside the pre tags in class_parser. It seems to have worked out in the end. A pain to set up. I wish someone that knew more about mybb/php/syntax highlighter could fix the existing plugin for future users though. 

This was us discussing the plugin fixes
http://python-forum.io/Thread-syntax-highlighting
NOTE: throughout this discussion we are disabling/re-enabling things. In the end shcode is disabled, and default code tags are routed to use the new syntax box.