修正识别问题

This commit is contained in:
joyqi
2013-12-03 20:27:43 +08:00
parent a8399ef1c2
commit b9cf37d815
+10
View File
@@ -1086,7 +1086,16 @@ else
}
function _DoItalicsAndBold(text) {
// <strong> must go first:
text = text.replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,
"<strong>$2</strong>");
text = text.replace(/(\*|_)(?=\S)([^\r]*?\S)\1/g,
"<em>$2</em>");
return text;
/*
// <strong> must go first:
text = text.replace(/([\W_]|^)(\*\*|__)(?=\S)([^\r]*?\S[\*_]*)\2([\W_]|$)/g,
"$1<strong>$3</strong>$4");
@@ -1095,6 +1104,7 @@ else
"$1<em>$3</em>$4");
return text;
*/
}
function _DoBlockQuotes(text) {