This project is read-only.
1
Vote

Cannot use a leading .. to exit above the top directory.

description

I keep getting this issue, I'll look into it more tomorrow.

If I debug it, it seems to be getting called twice. First time, it works fine, second time this error.

I have two menus on the page.

One of them has

url = "/"
url ="/news/"
url="http://www.google.com"

In case that helps you, I'll be looking into it more tomorrow.




2012-05-10 17:26:52,837 [28] Orchard.ContentManagement.Drivers.Coordinators.ContentPartDriverCoordinator - HttpException thrown from IContentPartDriver by Szmyd.Orchard.Modules.Menu.Drivers.MenuWidgetPartDriver
System.Web.HttpException (0x80004005): Cannot use a leading .. to exit above the top directory.
at System.Web.Util.UrlPath.ReduceVirtualPath(String path)
at System.Web.Util.UrlPath.Reduce(String path)
at System.Web.VirtualPath.Combine(VirtualPath relativePath)
at System.Web.Mvc.PathHelpers.GenerateClientUrlInternal(HttpContextBase httpContext, String contentPath)
at System.Web.Mvc.UrlHelper.GenerateUrl(String routeName, String actionName, String controllerName, RouteValueDictionary routeValues, RouteCollection routeCollection, RequestContext requestContext, Boolean includeImplicitMvcValues)
at System.Web.Mvc.UrlHelper.GenerateUrl(String routeName, String actionName, String controllerName, String protocol, String hostName, String fragment, RouteValueDictionary routeValues, RouteCollection routeCollection, RequestContext requestContext, Boolean includeImplicitMvcValues)
at System.Web.Mvc.UrlHelper.RouteUrl(RouteValueDictionary routeValues)
at Orchard.UI.Navigation.NavigationManager.GetUrl(String menuItemUrl, RouteValueDictionary routeValueDictionary) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\UI\Navigation\NavigationManager.cs:line 46
at Orchard.UI.Navigation.NavigationManager.FinishMenu(IEnumerable1 menuItems) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\UI\Navigation\NavigationManager.cs:line 38
at Orchard.UI.Navigation.NavigationManager.BuildMenu(String menuName) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\UI\Navigation\NavigationManager.cs:line 29
at Szmyd.Orchard.Modules.Menu.Drivers.MenuWidgetPartDriver.<>c__DisplayClassd.<Display>b__8() in c:\Work\svnroot\Site\Modules\Szmyd.Orchard.Modules.Menu\Drivers\MenuWidgetPartDriver.cs:line 46
at Orchard.ContentManagement.Drivers.ContentPartDriver
1.<>c__DisplayClassd.<ContentShape>b__c(BuildShapeContext ctx) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\ContentManagement\Drivers\ContentPartDriver.cs:line 108
at Orchard.ContentManagement.Drivers.ContentPartDriver1.<>c__DisplayClass13.<ContentShapeImplementation>b__12(BuildShapeContext ctx) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\ContentManagement\Drivers\ContentPartDriver.cs:line 116
at Orchard.ContentManagement.Drivers.ContentShapeResult.ApplyImplementation(BuildShapeContext context, String displayType) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\ContentManagement\Drivers\ContentShapeResult.cs:line 37
at Orchard.ContentManagement.Drivers.ContentShapeResult.Apply(BuildDisplayContext context) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\ContentManagement\Drivers\ContentShapeResult.cs:line 21
at Orchard.ContentManagement.Drivers.Coordinators.ContentPartDriverCoordinator.<>c__DisplayClassa.<BuildDisplay>b__9(IContentPartDriver driver) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\ContentManagement\Drivers\Coordinators\ContentPartDriverCoordinator.cs:line 49
at Orchard.InvokeExtensions.Invoke[TEvents](IEnumerable
1 events, Action`1 dispatch, ILogger logger) in C:\Work\svnroot\OrchardSource\1.4.0\src\Orchard\InvokeExtensions.cs:line 19

comments

Sarkie wrote May 11, 2012 at 2:10 PM

Follow up.

So it seems the Parts are getting called twice, for each Part. So I have two menus, Header and Footer. Each gets called twice.

The first time they'll work and no errors, the second time = boom.

In the old site, the menu items were just pure links, this time it was mix, urls and content items.

The urls in the content item are "drink/", I don't know if this is causing it to go boom. I've tried debugging it to no avail.

I've gone back to just using urls for a work-a-round.