title: asp net core read appsetting special character
body: <p>I need to read a value in the controller from the appsettings.json file and send it to the view. The value contains some special character, like letter with accent mark, for example "atención". </p>
  
  <p>The problem is that the special character is not shown properly.</p>
  
  <p>In the startup class I do that:</p>
  
  <pre><code>services.AddOptions();
  services.Configure&lt;ApplicationSettings(Configuration.GetSection("ApplicationSettings"));
  </code></pre>
  
  <p>Where <strong>ApplicationSettings</strong> is a class for hold the configuration values.</p>
  
  <p>And then in the controller:</p>
  
  <pre><code>private IOptions&lt;ApplicationSettings&gt; _settings;
  public StudentController(IOptions&lt;ApplicationSettings&gt; settings)
  {
      _settings = settings;
  }
  
  public IActionResult Index()
  {
      var testSetting = _settings.Value.TestSetting;
      return new ObjectResult(testSetting);
  }
  </code></pre>
  
  <p>testStting value has stranger's character instead of accent marks.</p>
  
  <p>Any idea?</p>
  
  <p>Thanks, regards!</p>