I am using ASP.NET MVC, and need to obtain and log Request Information.
I'm looking at Microsoft.AspNetCore.Http.HttpRequest and do not see ServerVariables. Has this been removed?
Is there a way I can get to the same data as I could via System.Web.HttpRequest.ServerVariables?
Thanks!
Philip
Microsoft.AspNetCore.Http.HttpRequest is as the namespace says part of asp.net core. The ServerVariables is a collection of variables provided by IIS. As asp.net core does not depend on IIS this property doesn't exist anymore.
If do not use asp.net core this is the HttpRequest class to use.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With