Fixed bug in reverse formatter (IE) with internal page link.

This commit is contained in:
Matteo Tomasini 2011-07-20 13:43:09 +02:00
parent ce45895e44
commit f4c18fda33
2 changed files with 9 additions and 4 deletions

View file

@ -16,5 +16,5 @@ using System.Reflection;
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersion("3.0.5.600")]
[assembly: AssemblyFileVersion("3.0.5.600")]
[assembly: AssemblyVersion("3.0.5.601")]
[assembly: AssemblyFileVersion("3.0.5.601")]

View file

@ -387,8 +387,13 @@ namespace ScrewTurn.Wiki {
string[] splittedLink = link.Split('=');
link = "c:" + splittedLink[1];
}
else if(pageLink) link = link.Remove(link.IndexOf(Settings.PageExtension));
else link = ProcessLink(link);
else if(pageLink) {
link = link.LastIndexOf('/') > 0 ? link.Substring(link.LastIndexOf('/') + 1) : link;
link = link.Remove(link.IndexOf(Settings.PageExtension));
}
else {
link = ProcessLink(link);
}
if(!anchor && !isTable && !childImg) {
if(title != link) result += "[" + target + link + "|" + ProcessChild(node.ChildNodes) + "]";
else result += "[" + target + link + "|" + ProcessChild(node.ChildNodes) + "]";