various fixes in server-side Markdown.OnQualifyUrl

The logic that was used was different from the JS version; the JS
version was more correct as just specifying UrlRootLocation would
give proper results but would fail in the server-side version. In
addition, a bug was fixed where the return value of QualifyUrl was
being ignored.