View Issue Details

IDProjectCategoryView StatusLast Update
0001890SOGoWeb Preferencespublic2012-09-20 14:33
Reporternoc_zs Assigned Toludovic  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version1.3.14 
Target Version2.0.0Fixed in Version2.0.0 
Summary0001890: Vacation message doesn't support french accents
Description

We have many customers who corresponds in French. We noticed that they are unable to save a vacation message if it contains accents.

They type the message, Hit "Save & close", no error message but when they go back in the vacation window the whole message is gone.

We replicated the problem here on many instances, different browsers, etc.

TagsNo tags attached.

Activities

piethein

piethein

2012-07-18 07:45

reporter   ~0004167

Strange, I have no issues with accents on my system, maybe you should list your setup/settings.

noc_zs

noc_zs

2012-07-18 12:54

reporter   ~0004172

Good thing you had me check back piethein.

I narrowed it to Firefox 13.0.1 (maybe other versions). I tested on Win 7 and Ubuntu 12.04.

I know we also had the same issue with a Mac but I do not have specific version on hand right now.

Worked in Chrome for Win 7 and Ubuntu.

ludovic

ludovic

2012-08-21 16:45

administrator   ~0004360

Probably a browser bug. Reopen if you have more evidence and can prove SOGo is the culprit here.

noc_zs

noc_zs

2012-09-18 14:25

reporter   ~0004484

I have noticed that SOGo relies on the AddDefaultCharset UTF-8 directive in the Apache configuration. The Content-Type header natively generated by SOGo is:

Content-Type: text/html

As we use Nginx, we can only remove the header and force it to "text/html; charset=UTF-8". This may break calendars as the mime type will be wrong for those requests.

SOGo should set the charset=UTF-8 sub-header as it is the content generator when accessing the /SOGo path.

Because of this behaviour, SOGo does not set the vacation message correctly sometimes. Because the charset is not declared explicitely, each browser may guess wrong (and differently) as to the real character encoding.

ludovic

ludovic

2012-09-20 12:56

administrator   ~0004499

Can you try this SOPE patch:

--- a/sope-appserver/NGObjWeb/SoObjects/SoDefaultRenderer.m
+++ b/sope-appserver/NGObjWeb/SoObjects/SoDefaultRenderer.m
@@ -128,7 +128,12 @@ static int debugOn = 0;
[self debugWithFormat:
@" as component (use appendToResponse:inContext:)"];
}

  • [r setHeader:@"text/html" forKey:@"content-type"];
  • if ([r contentEncoding] == NSUTF8StringEncoding)
  • [r setHeader:@"text/html; charset=utf-8" forKey:@"content-type"];
  • else
  • [r setHeader:@"text/html" forKey:@"content-type"];
  • [_ctx setPage:_c];
    [_ctx enterComponent:_c content:nil];
    [_c appendToResponse:r inContext:_ctx];

noc_zs

noc_zs

2012-09-20 14:00

reporter   ~0004508

Ok, I tried the patch and I could not reproduce the bug with Firefox. When using Firebug or the Chrome tools, I see that "charset=utf-8" is added correctly to text/html documents.

The bug is fixed by the above but you may want to check that the encoding is declared on every text document you send out. For example this path /SOGo/so/USER/Mail/0/mailboxes is a JSON document and the encoding is not declared.

Thanks for the help !

ludovic

ludovic

2012-09-20 14:28

administrator   ~0004510

The default encoding for application/json is UTF-8. This is specified in rfc4627.

ludovic

ludovic

2012-09-20 14:33

administrator   ~0004511

Fixed: https://github.com/inverse-inc/sope/commit/3a21618d2f4a995688c03344fc70d5b528259a4d

Issue History

Date Modified Username Field Change
2012-07-17 21:28 noc_zs New Issue
2012-07-18 07:45 piethein Note Added: 0004167
2012-07-18 12:54 noc_zs Note Added: 0004172
2012-08-21 16:45 ludovic Note Added: 0004360
2012-08-21 16:45 ludovic Status new => closed
2012-08-21 16:45 ludovic Resolution open => no change required
2012-09-18 14:25 noc_zs Note Added: 0004484
2012-09-18 14:25 noc_zs Status closed => feedback
2012-09-18 14:25 noc_zs Resolution no change required => reopened
2012-09-20 01:02 ludovic Status feedback => assigned
2012-09-20 01:02 ludovic Assigned To => ludovic
2012-09-20 01:02 ludovic Target Version => 2.0.0
2012-09-20 12:56 ludovic Note Added: 0004499
2012-09-20 14:00 noc_zs Note Added: 0004508
2012-09-20 14:28 ludovic Note Added: 0004510
2012-09-20 14:33 ludovic Note Added: 0004511
2012-09-20 14:33 ludovic Status assigned => closed
2012-09-20 14:33 ludovic Resolution reopened => fixed
2012-09-20 14:33 ludovic Fixed in Version => 2.0.0