aboutsummaryrefslogtreecommitdiffstats
path: root/library/mcefixes/plugins.bbcode.editor_plugin_src.js
diff options
context:
space:
mode:
authorVasudev Kamath <kamathvasudev@gmail.com>2012-07-06 22:47:27 +0530
committerVasudev Kamath <kamathvasudev@gmail.com>2012-07-06 22:47:27 +0530
commitba4db236ecff1ffdb56adc2715b3f53515f8cb34 (patch)
treef0b9928aade8aab95d1608890fde1918ce163754 /library/mcefixes/plugins.bbcode.editor_plugin_src.js
parent6e4760dd9c512147309b5e4a98d25216610f81da (diff)
parenta122fecf50d06856a2ada8b564f711fb52c327f0 (diff)
downloadvolse-hubzilla-ba4db236ecff1ffdb56adc2715b3f53515f8cb34.tar.gz
volse-hubzilla-ba4db236ecff1ffdb56adc2715b3f53515f8cb34.tar.bz2
volse-hubzilla-ba4db236ecff1ffdb56adc2715b3f53515f8cb34.zip
Merge branch 'master' of git://github.com/friendica/friendica
Diffstat (limited to 'library/mcefixes/plugins.bbcode.editor_plugin_src.js')
-rw-r--r--library/mcefixes/plugins.bbcode.editor_plugin_src.js16
1 files changed, 13 insertions, 3 deletions
diff --git a/library/mcefixes/plugins.bbcode.editor_plugin_src.js b/library/mcefixes/plugins.bbcode.editor_plugin_src.js
index a2829a21c..f94fbc5d7 100644
--- a/library/mcefixes/plugins.bbcode.editor_plugin_src.js
+++ b/library/mcefixes/plugins.bbcode.editor_plugin_src.js
@@ -46,10 +46,19 @@
function rep(re, str) {
+
+s = s.replace(re,str);
+
//modify code to keep stuff intact within [code][/code] blocks
//Waitman Gobble NO WARRANTY
+/* This doesn't seem to work well with
+[code]line1
+line2[/code]
+commenting out for now
+*/
+/*
var o = new Array();
var x = s.split("[code]");
var i = 0;
@@ -71,7 +80,7 @@
}
s = o.join("[code]");
-
+*/
};
@@ -150,8 +159,8 @@
rep(/<blockquote[^>]*>/gi,"[quote]");
rep(/<\/blockquote>/gi,"[/quote]");
rep(/<hr \/>/gi,"[hr]");
- rep(/<br (.*?)\/>/gi,"\n\n");
- rep(/<br\/>/gi,"\n\n");
+ rep(/<br (.*?)\/>/gi,"\n");
+ rep(/<br\/>/gi,"\n");
rep(/<br>/gi,"\n");
rep(/<p>/gi,"");
rep(/<\/p>/gi,"\n");
@@ -171,6 +180,7 @@
function rep(re, str) {
+
//modify code to keep stuff intact within [code][/code] blocks
//Waitman Gobble NO WARRANTY