]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-15893 tinymce integration does not use session anymore, there is still problem...
authorskodak <skodak>
Thu, 31 Jul 2008 09:41:12 +0000 (09:41 +0000)
committerskodak <skodak>
Thu, 31 Jul 2008 09:41:12 +0000 (09:41 +0000)
lib/editor/htmlEditor.class.php
lib/editor/tinymce.js.php

index 1a3a2de8cc8920bcd1ad791a6b144d76d5d11254..e405f426e219548563b642559fceaad4c70e69b0 100644 (file)
@@ -42,8 +42,10 @@ class htmlEditor {
         switch ($editor) {
 
             case 'tinymce':
+                $editorlanguage = substr(current_language(), 0, 2);
+                $direction = get_string('thisdirection');
                 $configuration[] = $CFG->httpswwwroot ."/lib/editor/tinymce/jscripts/tiny_mce/tiny_mce.js";
-                $configuration[] = $CFG->httpswwwroot ."/lib/editor/tinymce.js.php?course=". $courseid;
+                $configuration[] = $CFG->httpswwwroot ."/lib/editor/tinymce.js.php?course=$courseid&amp;editorlanguage=$editorlanguage&amp;direction=$direction";
                 $configured['tinymce'] = true;
                 break;
 
index a50335c4e6ed4c7f6fa73953a77527e764c0bb86..003ffbdf1ac1c01014d214fe574a77ac634a082b 100644 (file)
@@ -1,10 +1,12 @@
 <?php
 
+define('NO_MOODLE_COOKIES', true);
+
 require_once('../../config.php');
 
 $courseid = optional_param('course', 0, PARAM_INT);
-$editorlanguage = substr(current_language(), 0, 2);
-$directionality = get_string('thisdirection');
+$editorlanguage = optional_param('editorlanguage', 'en', PARAM_ALPHA);
+$directionality = optional_param('direction', get_string('thisdirection'), PARAM_ALPHA);
 
 /*
  * This section configures the TinyMCE toolbar buttons on and off