But all I get is this:
The page cannot be displayed because an internal server error has occurred.
This is what the log says:
[T69/D31] An unhandled exception occurred
System.InvalidOperationException: Sequence contains no elements
at System.Linq.Enumerable.First[TSource](IEnumerable`1 source)
at Umbraco.Web.Routing.NotFoundHandlerHelper.GetCurrentNotFoundPageId(IContentErrorPage[] error404Collection, String requestServerName, IEntityService entityService, PublishedContentQuery publishedContentQuery)
at Umbraco.Web.Routing.ContentFinderByLegacy404.TryFindContent(PublishedContentRequest pcr)
at Umbraco.Web.Routing.ContentLastChanceFinderByNotFoundHandlers.HandlePageNotFound(PublishedContentRequest docRequest)
at Umbraco.Web.Routing.ContentLastChanceFinderByNotFoundHandlers.TryFindContent(PublishedContentRequest docRequest)
at Umbraco.Web.Routing.PublishedContentRequestEngine.HandlePublishedContent()
at Umbraco.Web.Routing.PublishedContentRequestEngine.FindPublishedContentAndTemplate()
at Umbraco.Web.Routing.PublishedContentRequestEngine.PrepareRequest()
at Umbraco.Web.UmbracoModule.ProcessRequest(HttpContextBase httpContext)
at Umbraco.Web.UmbracoModule.
UrlRewrite won't work
I have a link looking like this: ~/find-dealer/dealer?did=1234
But I want a link looking like this: ~/find-dealer/dealer/what-ever-i-want/1234/
I thought this would do it:
But all I get is this: The page cannot be displayed because an internal server error has occurred.
This is what the log says: [T69/D31] An unhandled exception occurred System.InvalidOperationException: Sequence contains no elements at System.Linq.Enumerable.First[TSource](IEnumerable`1 source) at Umbraco.Web.Routing.NotFoundHandlerHelper.GetCurrentNotFoundPageId(IContentErrorPage[] error404Collection, String requestServerName, IEntityService entityService, PublishedContentQuery publishedContentQuery) at Umbraco.Web.Routing.ContentFinderByLegacy404.TryFindContent(PublishedContentRequest pcr) at Umbraco.Web.Routing.ContentLastChanceFinderByNotFoundHandlers.HandlePageNotFound(PublishedContentRequest docRequest) at Umbraco.Web.Routing.ContentLastChanceFinderByNotFoundHandlers.TryFindContent(PublishedContentRequest docRequest) at Umbraco.Web.Routing.PublishedContentRequestEngine.HandlePublishedContent() at Umbraco.Web.Routing.PublishedContentRequestEngine.FindPublishedContentAndTemplate() at Umbraco.Web.Routing.PublishedContentRequestEngine.PrepareRequest() at Umbraco.Web.UmbracoModule.ProcessRequest(HttpContextBase httpContext) at Umbraco.Web.UmbracoModule.
Apparently the only problem was that the name attribute cannot contain spaces.
So after changing name="Dealer Rewrite" to name="DealerRewrite" everything worked as intended.
is working on a reply...