TinyMCE editor language based on user profile

fleetcommand - June 23, 2008 - 08:36
Project:TinyMCE
Version:6.x-1.x-dev
Component:User interface
Category:feature request
Priority:normal
Assigned:Unassigned
Status:needs work
Description

Hi,

Currently you are able to set TinyMCE's language when editing a tinymce profile. It would be great if we have an option along with the language codes called "Based on user's profile" which would chose the language based of the user's own profile (if registered, otherwise the default language).

#1

zmove - July 23, 2008 - 12:44

/signed.

It's so logical to adapt the language of tinyMCE in the following order :

  1. The user language defined in his profile page
  2. The current language of the website
  3. The default tinyMCE language set up in the tinyMCE setting page

#2

geodaniel - August 26, 2009 - 12:31
Status:active» needs work

As a quick workaround, you can set TinyMCE to use the current interface language of the site by changing the following lines in tinymce.module:

<?php
global $language;

 
// $init['language']           = $settings['language'] ? $settings['language'] : 'en';
  // Use current interface language, not language configured in settings
 
$init['language']           = substr($language->language, 0, 2); // only take first two chars (e.g. 'pt', not 'pt-pt')
?>

It would be good to have this as an option in the settings instead of just overriding though.

 
 

Drupal is a registered trademark of Dries Buytaert.