From 2aacd6a4d73a0eb77f8526a90a36ce8b0ccc3b55 Mon Sep 17 00:00:00 2001 From: Justin Zeus Date: Wed, 25 Sep 2013 23:58:42 -0700 Subject: [PATCH] make lines starting with > a ref --- js/bbs/common.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/js/bbs/common.js b/js/bbs/common.js index c37342a..5b02eeb 100755 --- a/js/bbs/common.js +++ b/js/bbs/common.js @@ -58,10 +58,12 @@ function getQueryString() { function ansi2html(content) { // add color to reference - refertitle = new RegExp('\n(【 .* 】)', 'g'); - refercontent = new RegExp('\n(\: .*)', 'g'); + var refertitle = new RegExp('\n(【 .* 】)', 'g'); + var refercontent = new RegExp('\n(\: .*)', 'g'); + var refercontent2 = new RegExp('\n(> .*)', 'g'); content = content.replace(refertitle, '\n\u001b[1;33m$1\u001b[m'); content = content.replace(refercontent, '\n\u001b[36m$1\u001b[m'); + content = content.replace(refercontent2, '\n\u001b[36m$1\u001b[m'); content = html_encode(content); @@ -75,4 +77,4 @@ function ansi2html(content) { content = content.replace(monospacett, '\n'); return content; -} \ No newline at end of file +}