.NET Core MVC Page Not Refreshing After Changes
I’m building a .NET Core MVC on the latest version 2.2. I have a problem when I make changes to the CSHTML file … Read more
I’m building a .NET Core MVC on the latest version 2.2. I have a problem when I make changes to the CSHTML file … Read more
I need some help with the select tag helper in ASP.NET Core. I have a list of employees that I’m trying to bind … Read more
I’ve done this before with MVC5 using User.Identity.GetUserId() but that doesn’t seem to work here. The User.Identity doesn’t have the GetUserId() method. I … Read more
Back in RC1, I would do this: [HttpPost] public IActionResult Post([FromBody]string something) { try{ // … } catch(Exception e) { return new HttpStatusCodeResult((int)HttpStatusCode.InternalServerError); … Read more
Sending a form POST HTTP request (Content-Type: application/x-www-form-urlencoded) to the below controller results into a HTTP 415 Unsupported Media Type response. public class … Read more
Not sure what am I missing here but I am not able to get the values from my appsettings.json in my .net core … Read more
In appsettings.json { “MyArray”: [ “str1”, “str2”, “str3” ] } In Startup.cs public void ConfigureServices(IServiceCollection services) { services.AddSingleton<IConfiguration>(Configuration); } In HomeController public class … Read more
How do I get the Development/Staging/production Hosting Environment in the ConfigureServices method in Startup? public void ConfigureServices(IServiceCollection services) { // Which environment are … Read more
Can you please let me know how to get client IP address in ASP.NET when using MVC 6. Request.ServerVariables[“REMOTE_ADDR”] does not work. 22 … Read more
I created an .NET Core MVC application and use Dependency Injection and Repository Pattern to inject a repository to my controller. However, I … Read more