Fix url rewriter to deal with absolute URLs and those with query strings...

....