summaryrefslogtreecommitdiff
path: root/program/steps
diff options
context:
space:
mode:
authoralecpl <alec@alec.pl>2008-04-16 08:36:16 +0000
committeralecpl <alec@alec.pl>2008-04-16 08:36:16 +0000
commit33bb9826a76f9d6fabe343346a731925a42f0aa3 (patch)
treed1593e3ea8626f16fce5ecb472c9b4d20284a493 /program/steps
parent3dd0f253339e7f8e2aef6567987709c07b5d4e7f (diff)
- added tinyMCE localization setting
- don't use tiny_mce_src.js
Diffstat (limited to 'program/steps')
-rw-r--r--program/steps/settings/edit_identity.inc9
1 files changed, 8 insertions, 1 deletions
diff --git a/program/steps/settings/edit_identity.inc b/program/steps/settings/edit_identity.inc
index d8802ca8c..37fbbcaff 100644
--- a/program/steps/settings/edit_identity.inc
+++ b/program/steps/settings/edit_identity.inc
@@ -39,10 +39,17 @@ function rcube_identity_form($attrib)
{
global $IDENTITY_RECORD, $OUTPUT;
- $OUTPUT->include_script('tiny_mce/tiny_mce_src.js');
+ $tinylang = substr($_SESSION['user_lang'], 0, 2);
+ if (!file_exists('program/js/tiny_mce/langs/'.$tinylang.'.js'))
+ {
+ $tinylang = 'en';
+ }
+
+ $OUTPUT->include_script('tiny_mce/tiny_mce.js');
$OUTPUT->add_script("tinyMCE.init({ mode : 'textareas'," .
"editor_selector : 'mce_editor'," .
"apply_source_formatting : true," .
+ "language : '$tinylang'," .
"content_css : '\$__skin_path' + '/editor_content.css'," .
"theme : 'advanced'," .
"theme_advanced_toolbar_location : 'top'," .