(zero V unu)

Solve: “m.lang.contextmenu is undefined” error message

I got this error while developing a website. It was odd the problema was not already reported, but that was because of the diferent language of the visitors.

The problem seems to be from the CKEditor language detection mechanism, I tried alerted

The file in /ckeditor/lang/  was called ‘en.js’ so probably they expected the language code to be just ‘en’.

The fast solution was to add this in the CKEDITOR.editorConfig function  (config.js file)

There might be a better solution detecting all posibilities ‘en-gb’, ‘en-us’ etc. or with some Regexp like