From 4847873e256f5472e4b841b2a5c2ba6188add668 Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Thu, 12 Feb 2015 17:08:27 -0800 Subject: [PATCH] better fix for #24331 --- httemplate/elements/ckeditor/plugins/blockprotect/plugin.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/httemplate/elements/ckeditor/plugins/blockprotect/plugin.js b/httemplate/elements/ckeditor/plugins/blockprotect/plugin.js index 376d2bc3c..e4ef39167 100644 --- a/httemplate/elements/ckeditor/plugins/blockprotect/plugin.js +++ b/httemplate/elements/ckeditor/plugins/blockprotect/plugin.js @@ -7,6 +7,7 @@ var delim_c = '}'; var create_block = function(content, inside) { + if (inside) return content; // fix nbsp's content = content.replace(/ /gi, ' '); // escape the content @@ -18,12 +19,7 @@ el.innerText = content; } el.setAttribute('class', 'cke_blockprotect'); - if (inside) { - return el.innerHTML; // escapes the contents but doesn't wrap - // them in a - } else { - return el.outerHTML; - } + return el.outerHTML; }; var block_writeHtml = function( element ) { // to unescape the element contents, write it out as HTML, -- 2.11.0