We had a requirement to remove the port number from the
The code I used for this is
string newUrl = context.Request.Url.AbsoluteUri.Replace(":" + context.Request.Url.Port, string.Empty);
This is working fine. but I'm eager to know is there any better way to do this?