[Mono-list] wrong encoding utf-8 - iso-8859-1

Alois.Flammensboeck at iXTS.de Alois.Flammensboeck at iXTS.de
Thu Oct 27 11:30:53 EDT 2005


Hello,

after 3 days of unsucessfully work I decided today to write a question to this list. I've installed mono 1.1.8 with mod_mono on a linux server. Everything works fine but I'm not able to create any ASP.Net pages with german special chars.
Here are the steps I'll follow:

1. Create a asp.net page with following content in Borland Delphi 2005 and save it in utf-8 format:

<%@ Page Language="c#" Debug="true" Codebehind="WebForm1.pas" AutoEventWireup="false" Inherits="WebForm1.TWebForm1"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>
  <head>
	<title></title>
  </head>
  <body ms_positioning="GridLayout">
	<form runat="server">
	ä ö ü </form>
  </body>
</html>

2. Compile this webapplication in Delphi 2005

3. upload the WebForm1.aspx and the corresponding assembly

4. Upload the Web.config with the following globalization section:
    <globalization 
                                    requestEncoding="utf-8"
			responseEncoding="utf-8"
                                    fileEncoding="utf-8"

   />

The resulting page I see in the web browser is:

 ä ö ü

The browser is set to Unicode(utf-8). 

If I change the responseEncoding in web.config to "iso-8859-1". The same page is shown but the browser is set to Western(iso-8859-1). If I then manually change the browsers encoding to Unicode(utf-8) everything is fine.

Does anybody know how to solve this strange problem?

Thanks in advance
Alois




More information about the Mono-list mailing list