Page 1 of 1

Environment variables

Posted: Thu Sep 14, 2017 12:31 pm
by cheemingyong

hi anyone knows how environment variables are packaged in asp.net maker ?

right now things like server.mappath which i need to draw the location of the wwwroot is not working
anymore in .NET core

is this situation addressed in the .NET core version of asp.net maker ?


Re: Environment variables

Posted: Fri Sep 15, 2017 9:27 am
by Webmaster

The hosting environment service in ASP.NET Core (IHostingEnvironment) can be accessed via the static variable: ew_Env

Google for "ASP.NET Core Server.MapPath" if you want to find the ASP.NET Core equivalent of Server.MapPath.