Reading files with ASP.NET Core

Replacing Server.MapPath when using ASP.NET Core Developers will quickly find that the method Server.MapPath has not been included in ASP.NET Core. However, the interface IHostingEnvironment can be used to resolve file paths. Here is an example to get a list of all shared views in your project. Use the Controller to get the path In your controller, use […]

Read More…