Start a conversation

Troubleshooting 404 URL Redirects Error

Overview

You may encounter a 404 error when using redirects configured in the Pages > Advanced > SEO section. This error is associated with the Advanced URL Rewriter, and the error message below is seen in the logs.

Exception: Error executing child request for ~/Default.aspx.Stack Trace:    at System.Web.HttpServerUtility.Execute(String path, TextWriter writer, Boolean preserveForm)   at System.Web.HttpServerUtility.Transfer(String path, Boolean preserveForm)   at DotNetNuke.Entities.Urls.AdvancedUrlRewriter.Handle404OrException(FriendlyUrlSettings settings, HttpContext context, Exception ex, UrlAction result, Boolean transfer, Boolean showDebug)   at DotNetNuke.Entities.Urls.AdvancedUrlRewriter.ProcessRequest(HttpContext context, Uri requestUri, Boolean useFriendlyUrls, UrlAction result, FriendlyUrlSettings settings, Boolean allowSettingsChange, Guid parentTraceId)Inner Ex : Object reference not set to an instance of an object.Stack Trace:    at System.Web.HttpServerUtility.Execute(String path, TextWriter writer, Boolean preserveForm)

Root Cause

This issue was caused by the use of an extension in the URL Path

Solution

To resolve this issue, create the URL Redirect without the .aspx extension. For example, when providing the 'URL Path', input '/news/mediaroom' instead of '/news/mediaroom.aspx'. This adjustment should resolve the 404 error.

Summary

404 errors in URL redirects can be resolved by creating the URL Redirect without the URL extension. This means when providing the 'URL Path', you should input '/news/mediaroom' not '/news/mediaroom.aspx'.

 

Choose files or drag and drop files
Was this article helpful?
Yes
No
  1. Priyanka Bhotika

  2. Posted

Comments