Mathijs den Burger pushed to branch release/2.26 at cms-community / hippo-cms
Commits: 3affe88c by Marijan Milicevic at 2016-03-03T13:42:21+01:00 CMS-9962 IE11 throws createStyleSheet error: method not supported - check if ie version is less than 11 - - - - - 767ae18d by Mathijs den Burger at 2016-03-09T14:59:30+01:00 CMS-9962 Reintegrate bugfix/CMS-9962 - - - - - 1 changed file: - richtext/ckeditor/frontend/src/main/java/org/hippoecm/frontend/plugins/ckeditor/CKEditorPanel.js Changes: ===================================== richtext/ckeditor/frontend/src/main/java/org/hippoecm/frontend/plugins/ckeditor/CKEditorPanel.js ===================================== --- a/richtext/ckeditor/frontend/src/main/java/org/hippoecm/frontend/plugins/ckeditor/CKEditorPanel.js +++ b/richtext/ckeditor/frontend/src/main/java/org/hippoecm/frontend/plugins/ckeditor/CKEditorPanel.js @@ -156,16 +156,16 @@ }); }; - if (Wicket.Browser.isIE()) { + if (Wicket.Browser.isIELessThan11()) { CKEDITOR_READY.when(function() { /* - Replace CKEditor's 'appendStyleText' method. IE chokes on the original because it calls createStyleSheet() + Replace CKEditor's 'appendStyleText' method. IE < 11 chokes on the original because it calls createStyleSheet() with an empty string as argument. That throws an Error when the page is served by an HTTP server. */ CKEDITOR.dom.document.prototype.appendStyleText = function(cssStyleText) { - var style = this.$.createStyleSheet(); - style.cssText = cssStyleText; - return style; + var styleSheet = this.$.createStyleSheet(); + styleSheet.cssText = cssStyleText; + return styleSheet; }; }); } View it on GitLab: https://code.onehippo.org/cms-community/hippo-cms/compare/3b0537822f76cea9d4653b003de26a3ed2c305cf...767ae18d7dceaff269ea398e6f5fcb51a5d79acb
_______________________________________________ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn