Fixed bug #11863: htmlArea RTE: css syntax errors in language marks feature
authorStanislas Rolland <typo3@sjbr.ca>
Thu, 3 Sep 2009 21:26:55 +0000 (21:26 +0000)
committerStanislas Rolland <typo3@sjbr.ca>
Thu, 3 Sep 2009 21:26:55 +0000 (21:26 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@5890 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/sysext/rtehtmlarea/htmlarea/plugins/Language/language.js
typo3/sysext/rtehtmlarea/htmlarea/skins/default/htmlarea-edited-content.css
typo3/sysext/t3skin/rtehtmlarea/htmlarea-edited-content.css

index d7575fa..a9417f6 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -11,6 +11,7 @@
 2009-09-03  Stanislas Rolland  <typo3@sjbr.ca>
 
        * Updated htmlArea RTE version to 1.8.3 for TYPO3 4.3beta1
+       * Fixed bug #11863: htmlArea RTE: css syntax errors in language marks feature
 
 2009-09-02  Ingo Renner  <ingo@typo3.org>
 
index 86543ab..dc9bf3f 100644 (file)
@@ -143,11 +143,15 @@ Language = HTMLArea.Plugin.extend({
                        var options = select.options;
                        var rule, selector, style;
                        for (var i = options.length; --i >= 0;) {
-                               selector = 'body.htmlarea-show-language-marks *[' + (this.useAttribute.lang ? 'lang=' : 'xml:lang=') + options[i].value + ']:before';
-                               style = 'content: "' + options[i].value + ': "';
-                               rule = selector + ' { ' + style + '; }';
+                               selector = 'body.htmlarea-show-language-marks *[' + 'lang="' + options[i].value + '"]:before';
+                               style = 'content: "' + options[i].value + ': ";';
+                               rule = selector + ' { ' + style + ' }';
                                if (HTMLArea.is_gecko) {
-                                       styleSheet.insertRule(rule, styleSheet.cssRules.length);
+                                       try {
+                                               styleSheet.insertRule(rule, styleSheet.cssRules.length);
+                                       } catch (e) {
+                                               this.appendToLog("onGenerate", "Error inserting css rule: " + rule + " Error text: " + e);
+                                       }
                                } else {
                                        styleSheet.addRule(selector, style);
                                }
index 9709f1d..d647d6a 100644 (file)
@@ -18,9 +18,6 @@ body.htmlarea-showtableborders table, body.htmlarea-showtableborders td, body.ht
 body.htmlarea-show-language-marks *[lang] {
        background: url("images/language-marker.gif") left bottom no-repeat; padding-left: 14px; text-decoration: underline;
 }
-body.htmlarea-show-language-marks *[xml:lang] {
-       background-image: url("images/language-marker.gif"); background-position: left bottom; background-repeat: no-repeat; padding-left: 14px; text-decoration: underline;
-}
 
 /* Selectors for the Abbreviation plugin */
 body.htmlarea-content-body abbr, body.htmlarea-content-body acronym {
index 9709f1d..d647d6a 100644 (file)
@@ -18,9 +18,6 @@ body.htmlarea-showtableborders table, body.htmlarea-showtableborders td, body.ht
 body.htmlarea-show-language-marks *[lang] {
        background: url("images/language-marker.gif") left bottom no-repeat; padding-left: 14px; text-decoration: underline;
 }
-body.htmlarea-show-language-marks *[xml:lang] {
-       background-image: url("images/language-marker.gif"); background-position: left bottom; background-repeat: no-repeat; padding-left: 14px; text-decoration: underline;
-}
 
 /* Selectors for the Abbreviation plugin */
 body.htmlarea-content-body abbr, body.htmlarea-content-body acronym {