pettanr_simple_format 0.0.8 → 0.0.9
Sign up to get free protection for your applications and to get access to all the features.
@@ -9,8 +9,9 @@ class PettanrSimpleFormat
|
|
9
9
|
text = PettanrSimpleFormat.escapeHTML(content)
|
10
10
|
start_tag = '<p>'
|
11
11
|
text = text.replace(/\r\n?/g, "\n")
|
12
|
-
text = text.replace(/\n\n+/g, "</p
|
13
|
-
text = text.replace(
|
12
|
+
text = text.replace(/\n\n+/g, "</p><p>")
|
13
|
+
text = text.replace(/\n/g, '\n<br />')
|
14
|
+
text = text.replace(/\<\/p\>\<p\>/g, "</p>\n\n<p>")
|
14
15
|
text = start_tag + text + "</p>"
|
15
16
|
return text
|
16
17
|
|