London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!
AI OnAI Off
London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!
Hi Paul,
Did you register your path in the Initialisation module.
It should look something like this as below
public void Initialize(InitializationEngine context) {
var partialRouter = new SharedNewsRouter();
RouteTable.Routes.RegisterPartialRouter(partialRouter);
}
Yes my IPartialRouter is registered and get's called when the page is rendered in edit mode, but not view mode.
I am trying to do some partial routing for my custom object, something similar to this: http://world.episerver.com/blogs/Johan-Bjornfot/Dates1/2012/11/Partial-Routing/
When I call UrlResolver.Current.GetVirtualPathForNonContent with my custom object, the url it generates is "currentpage/?routedData=MyCustomDataClass" and my IPartialRouter.GetPartialVirtualPath method is never called. Wonder what I'm missing? Bizarely, it works in edit mode (as in, my IPartialRouter is called and it generates the correct url)