Opened 17 years ago

Closed 17 years ago

#1567 closed New Feature (duplicate)

MediaWiki plugin localization

Reported by: B_aniaczek Owned by:
Priority: Normal Milestone:
Component: Project : MediaWiki+FCKeditor Version:
Keywords: Cc:

Description

It would be great to have mediaWiki plugin localized to user language, like FCKeditor. Most things are localized, but mediaWiki specific strings are English only.

Things to do: File FCKeditor/fckeditor_config.js: Add before FCKConfig.Plugins.Add( 'mediawiki' ) ; lines: var MediaWikiPluginAvailableLanguages = {

en : 'English', pl : 'Polish'

}; var MediaWikiPluginLanguage = 'pl';

and modify line:

FCKConfig.Plugins.Add( 'mediawiki' ) ;

to have

FCKConfig.Plugins.Add( 'mediawiki' , MediaWikiPluginLanguage ) ;

I have no idea, how to use mediaWiki settings (see ticket 1565) :(

Create directory FCKeditor/plugins/mediawiki/lang and put there en.js and pl.js (attached)

Modify files: fckplugin.js, image.html, link.html, math.html, ref.html, template.html. There is to many changes to describe them. To find differences simply look at attached my versions and look for strings: .wiki and "wiki" and search for function plural (inside image.html and link.html only).


Note about function plural( thingsToCount, found0, found1, foundSeveral, foundMore ) It returns: *found0 if there is no thingsToCount, *found1 if there is one thingsToCount, *foundSeveral if there is: 2,3,4, 22,23,24, 32,33,34, 42,43,44, ..., 102,103,104 ... and so on (but not 12,13,14,112,113,114) thingsToCount, *foundMore otherwise It is polish specific behavior. English users (this is probably the same in many other languages) should use foundSeveral same as foundMore. In fact - plural is language specific and it should be loaded with language file, but I'm noob with javaScript to code it :( For examples look for language files in mediaWiki installation: /languages/classes/Language*.php)

Attachments (8)

en.js (2.9 KB) - added by B_aniaczek 17 years ago.
English translation
pl.js (3.2 KB) - added by B_aniaczek 17 years ago.
Polish translation
fckplugin.js (21.4 KB) - added by B_aniaczek 17 years ago.
Plugin body
image.html (9.9 KB) - added by B_aniaczek 17 years ago.
Dialog
link.html (6.2 KB) - added by B_aniaczek 17 years ago.
Dialog
math.html (3.5 KB) - added by B_aniaczek 17 years ago.
Dialog
ref.html (3.3 KB) - added by B_aniaczek 17 years ago.
Dialog
template.html (3.3 KB) - added by B_aniaczek 17 years ago.
Dialog

Download all attachments as: .zip

Change History (10)

Changed 17 years ago by B_aniaczek

Attachment: en.js added

English translation

Changed 17 years ago by B_aniaczek

Attachment: pl.js added

Polish translation

Changed 17 years ago by B_aniaczek

Attachment: fckplugin.js added

Plugin body

Changed 17 years ago by B_aniaczek

Attachment: image.html added

Dialog

Changed 17 years ago by B_aniaczek

Attachment: link.html added

Dialog

Changed 17 years ago by B_aniaczek

Attachment: math.html added

Dialog

Changed 17 years ago by B_aniaczek

Attachment: ref.html added

Dialog

Changed 17 years ago by B_aniaczek

Attachment: template.html added

Dialog

comment:1 Changed 17 years ago by B_aniaczek

Sorry for duplicated post. It was not clear, how to add attachments. Please remove this post and take a look at #1569

comment:2 Changed 17 years ago by Martin Kou

Keywords: localization removed
Resolution: duplicate
Status: newclosed

Marked as dup of #1569.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy