Skip to content
Snippets Groups Projects
Commit 8dae0f76 authored by Andreas Valder's avatar Andreas Valder
Browse files

javascript string replace...

parent a6f18878
No related branches found
No related tags found
No related merge requests found
......@@ -63,10 +63,10 @@ var moderator = {
},
editor: {
fromhtml: function (str) {
return str.replace('<br>', '\n')
return str.replace(/<br>/g, '\n')
},
tohtml: function (str) {
return str.replace('\n', '<br>')
return str.replace(/\n/g, '<br>')
},
init: function() {
var editable = $('.moderator_editor');
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment