core
core copied to clipboard
Encoding GB2312 is not available on Windows.
Issue Title
Encoding GB2312 is not available on Windows.
General
If we try to use HttpClient.GetString for a GB2312 response, it throws exception. Actually GB2312 encoding is quite important for Chinese developers. Please consider to fix it.
@stdcppdev This is quite known problem in .NET Core because Some codepages needs to be registered. It's quite easy to fix.
If you are using .NET Core 2.0, in your app entry point (such as main), use this:
System.Text.Encoding.RegisterProvider(new CodePagesEncodingProvider())
@eriawan Yes, it works. Thanks! Close for resolved.