iso-8859-1 in webservice-responses

  • Thread starter bernhard gruber via .NET 247
  • Start date
B

bernhard gruber via .NET 247

Hi,

I have a webservice in c#.net.
I want to send all the responses of the webservice encoded in "iso-8859-1", so that german special characters will be displayed correctly.

I put this line in both files, machine.config and web.config:

<globalization requestEncoding="iso-8859-1" responseEncoding="iso-8859-1"/>


Still every response starts like that:

<?xml version="1.0" encoding="utf-8"?>

UTF-8 (!!) and all the special characters are questionmarks ???

any help would be great

thanks

bernie
 
B

Bruno Jouhier [MVP]

I don't know why it does not work, but I'm wondering why you want to use
ISO-8859-1 instead of UTF-8.

UTF-8 supports German characters and you should only use ISO-8859-1 if you
have to deal with legacy systems that don't understand UTF-8.
Usually, web services are produced and consumed by layers that are written
in modern technologies (.NET, Java). So, why use an old standard here?

Bruno.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top