Tuesday, 24 February 2009

Installing with Configure present - Edittools fun

I am really pleased announcing Configure support for the installation of extensions. Now when you install an extension, it will leave the enabling and the configuration to Configure. I asked for it, it is important and now I have to come to grips with it.

One of the things that it has is a button to enable an extension.. That is good. It does not necessarily help me understand how things work. The Edittools is one of my favourites and it needs CharInsert. So I enabled it and it does not give me my drop down box that should be there..

One of the friendly people at IRC told me about the existence of Edittools.js but is was not clear if this was what I had to install.

So it seems that there is functionality that needs all kinds of components, there is the message, there is the Edittools message, There is the Edittools.js and there is the CharInsert extension.

So how do I activate the Edittools.js and what to do with: "the dropdown is added by Edittools.js if document.getElementById('specialchars'). This is a bit inefficient though, and it is rather outdated code". I know for a fact that it is used on LOADS of MediaWiki servers..
Thanks,
GerardM

4 comments:

Tgr said...

You need CharInsert, you need to have the characters listed in the expected format in the relevant system message (MediaWiki:Edittools I think), plus you need to run the javascript on every page load that inserts the dropdown. You can accomplish that either by adding it to MediaWiki:Monobook.js or MediaWiki:Common.js (if you want it to work in all skins), or if you have it in a sepatate js file, you have to load it from monobook.js or common.js (this is normally done with "importScript(Edittools.js);").

If you want all this from an installer, and backwards-compatible with earlier MW versions, that will be a pain in the ass: importScript has been added recently, common.js did not always exist either, MediaWiki:Edittools used to contain only {{Project:Edittools}} to avoid a bug with templates in charinsert tags, and so on.

GerardM said...

Hoi,
Your points prove a point; it is a mess and you need a lot of skills and prior knowledge before you can maintain MediaWiki.

This mess makes the maintenance of MediaWiki expensive for people and organisations who use stable versions of MediaWiki. This is what we hope to improve.
Thanks,
GerardM

Andrew said...

Configure's support for extensions is a bit of a horrible mess, unfortunately.

It's pretty nifty for core stuff, though.

GerardM said...

What I have seen so far of Configure and extensions gives me the impression that the Extensions are a mess and that Configure is part of the solution.
Thanks,
GerardM