Fixed and closed #364: all HTML comments are stripped away except for ones inside PRE tags.
This commit is contained in:
parent
99ef640d48
commit
bd65c84133
2 changed files with 11 additions and 9 deletions
|
@ -16,5 +16,5 @@ using System.Reflection;
|
||||||
//
|
//
|
||||||
// You can specify all the values or you can default the Revision and Build Numbers
|
// You can specify all the values or you can default the Revision and Build Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
[assembly: AssemblyVersion("3.0.0.347")]
|
[assembly: AssemblyVersion("3.0.0.348")]
|
||||||
[assembly: AssemblyFileVersion("3.0.0.347")]
|
[assembly: AssemblyFileVersion("3.0.0.348")]
|
||||||
|
|
|
@ -150,13 +150,6 @@ namespace ScrewTurn.Wiki {
|
||||||
match = JavascriptRegex.Match(sb.ToString(), match.Index + 1);
|
match = JavascriptRegex.Match(sb.ToString(), match.Index + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Strip out all comments
|
|
||||||
//match = CommentRegex.Match(sb.ToString());
|
|
||||||
//while(match.Success) {
|
|
||||||
// sb.Remove(match.Index, match.Length);
|
|
||||||
// match = CommentRegex.Match(sb.ToString(), match.Index + 1);
|
|
||||||
//}
|
|
||||||
|
|
||||||
// Remove empty NoWiki and NoBr tags
|
// Remove empty NoWiki and NoBr tags
|
||||||
sb.Replace("<nowiki></nowiki>", "");
|
sb.Replace("<nowiki></nowiki>", "");
|
||||||
sb.Replace("<nobr></nobr>", "");
|
sb.Replace("<nobr></nobr>", "");
|
||||||
|
@ -834,6 +827,15 @@ namespace ScrewTurn.Wiki {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Strip out all comments
|
||||||
|
if(!bareBones) {
|
||||||
|
match = CommentRegex.Match(sb.ToString());
|
||||||
|
while(match.Success) {
|
||||||
|
sb.Remove(match.Index, match.Length);
|
||||||
|
match = CommentRegex.Match(sb.ToString(), match.Index + 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Remove <nowiki> tags
|
// Remove <nowiki> tags
|
||||||
if(!bareBones) {
|
if(!bareBones) {
|
||||||
sb.Replace("<nowiki>", "");
|
sb.Replace("<nowiki>", "");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue