Support for running Umbraco from a network drive.

This commit is contained in:
niels.kuhnel
2012-10-25 08:14:10 -02:00
parent 79488a43da
commit 632d9f171e

View File

@@ -85,9 +85,11 @@ namespace Umbraco.Core.IO
public static string MapPath(string path, bool useHttpContext)
{
// Check if the path is already mapped
if (path.Length >= 2 && path[1] == Path.VolumeSeparatorChar)
if ((path.Length >= 2 && path[1] == Path.VolumeSeparatorChar)
|| path.StartsWith(@"\\")) //UNC Paths start with "\\". If the site is running off a network drive mapped paths will look like "\\Whatever\Boo\Bar"
{
return path;
}
// Check that we even have an HttpContext! otherwise things will fail anyways
// http://umbraco.codeplex.com/workitem/30946