diff --git a/js/qvitter.js b/js/qvitter.js index 561fcd0..e1b7d9c 100644 --- a/js/qvitter.js +++ b/js/qvitter.js @@ -2852,9 +2852,9 @@ $('body').on('click', '.queet-toolbar button',function () { // In firefox (and maybe some other browsers), queetBox.html() may have
s // and may or may not have
in them. // To deal with this, remove any
s right before
and then add ones. - queetBox.html(queetBox.html().replace(/(
)*<\/div>/g, '
').replace(/
/g, '{{{lb}}}')); + queetBox.html(queetBox.html().replace(/(
)*<\/div>/g, '
').replace(/({|})/g, '!$1').replace(/
/g, '{{{lb}}}')); var queetText = $.trim(queetBox.text().replace(/^\s+|\s+$/g, '').replace(/\n/g, '')); - queetText = queetText.replace(/{{{lb}}}/g, "\n"); + queetText = queetText.replace(/{{{lb}}}/g, "\n").replace(/!({|})/g, '$1'); var queetTempText = replaceHtmlSpecialChars(queetText.replace(/\n/g,'
')); // no xss queetTempText = queetTempText.replace(/<br>/g,'
'); // but preserve line breaks