Skip to content
This repository has been archived by the owner on Oct 20, 2024. It is now read-only.

Logger throwing an error #3

Open
juanp123 opened this issue Feb 17, 2013 · 0 comments
Open

Logger throwing an error #3

juanp123 opened this issue Feb 17, 2013 · 0 comments

Comments

@juanp123
Copy link

Turning on logging with

RewriteLog "log.txt"
RewriteLogLevel 9

cause an error
Failed to map the path '/log.txt'.

pathRoot = Path.DirectorySeparatorChar.ToString();

Line 217: // our web application root directory
Line 218: if (pathRoot == Path.DirectorySeparatorChar.ToString())
Line 219: path = HostingEnvironment.MapPath( path);

Source File: C:\Orchard.Source.1.6\src\managedfusion-rewriter-master\src\RuleSet.cs Line: 219

I believe what you want in the code above the error is as follows, so that the mapping is relative to the application path. I have not tested all the code paths though, so this may introduce other errors.

path = "~" + pathRoot + path;

(and not path = pathRoot + path; )

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant