Add syntax highlighting to Edit box


Author: kovo1

The CodePress project ( has an excellent <textarea>-style input box which automatically highlights syntax while it is being edited. It currently has support for PHP, JavaScript, Java, Perl, SQL, HTML, and CSS. I would love to see a cooperative project to add support for MediaWiki syntax, so that we could use the CodePress edit box instead of the simple <textarea> currently in use by MediaWiki. This would make learning MediaWiki syntax a great deal easier on new editors and make editing a lot easier for experienced editors.

Version: 1.22.0
Severity: enhancement

bzimport added a project: MediaWiki-Page-editing.Via ConduitNov 21 2014, 9:57 PM
bzimport added a subscriber: wikibugs-l.
bzimport set Reference to bz11627.
bzimport created this task.Via LegacyOct 10 2007, 8:28 PM
brion added a comment.Via ConduitDec 5 2007, 8:21 PM
  • Bug 11886 has been marked as a duplicate of this bug. ***
Patrick87 added a comment.Via ConduitApr 25 2013, 9:54 PM

This actually is a great idea!

In the end the MediaWiki syntax is some kind of source code after all (even if it's syntax is really easy) and syntax higlighting is always a huge help for reading through source code of all kinds.

If the built-in editor would contain some basic syntax highlighting this would help new editor to learn wiki syntax and made editing for experienced users more comfortable.

I already found a JavaScript with such functionality ( and I don't see any reason why something like this shouldn't be included in the MediaWiki software (and on all Wikimedia projects) by default.

drdee added a comment.Via ConduitNov 19 2013, 3:59 AM

What's the status of this?

Pastakhov added a comment.Via ConduitSep 22 2014, 11:06 AM

I am developing the CodeMirror extension [1] that highlights the wiki markup in <textarea>. It is not ready for real usage yet, but you can already see how it work [2] and help me to make it more usable.

Also I'm going to implement a function described in bug 13302.

Somehow these topics are avoided for a long time therefore I doubt that there is any way to integrate this solution into mediawiki software.

In any case, I'm going to continue working on this extension, and if there is someone interested in this solution, let me know.


Add Comment

Column Prototype
This is a very early prototype of a persistent column. It is not expected to work yet, and leaving it open will activate other new features which will break things. Press "\" (backslash) on your keyboard to close it now.