crowell / modpagespeed_tmp

Automatically exported from code.google.com/p/modpagespeed
Apache License 2.0
0 stars 0 forks source link

iso8859-1 site gets accents stripped #552

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Activate latest version on a page with iso8859-1 charset
2. The accents are gone

What is the expected output? What do you see instead?
When I activate modpagespeed the accents on my page become strange characters 
(question marks etc)
In my apache configuration file I correctly set the AddDefaultCharset directive.

What version of the product are you using (please check X-Mod-Pagespeed
header)?
latest stable version

On what operating system? Centos6

Which version of Apache?
apache 2

Which MPM?
prefork

URL of broken page:
I had to disable it because of this problem

Original issue reported on code.google.com by Josie...@gmail.com on 28 Oct 2012 at 9:21

GoogleCodeExporter commented 9 years ago
Summary was: Charset/Accents problem

Please give us the URL anyway.  Also the exact 'AddDefaultCharset' directive.  
That will make it much easier to repro the problem.

If you disabled mod_pagespeed via 'ModPagespeed off' in your config file, but 
leave it installed, that will be even better.

But we do need a URL to repro.

btw we do have other sites using iso8859-1 with non-ascii characters and so we 
need to see why it is not working for your site in particular.

Original comment by jmara...@google.com on 28 Oct 2012 at 11:09

GoogleCodeExporter commented 9 years ago
The url is gossip . it (whithout spaces).

The directive in my Apache config is AddDefaultCharset ISO-8859-1

Original comment by Josie...@gmail.com on 29 Oct 2012 at 12:22

GoogleCodeExporter commented 9 years ago
IIRC, Apache's AddDefaultCharset is applied after mod_pagespeed sees the file, 
which means mod_pagespeed doesn't see that header.
You site has this line, which will make mod_pagespeed believe the page is UTF-8:
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

This might explain the problem. Can you change the meta tag to iso-8859-1 to 
match the header?

Original comment by matterb...@google.com on 29 Oct 2012 at 1:38

GoogleCodeExporter commented 9 years ago
Ping? Are you able to try out my suggestion please?

Original comment by matterb...@google.com on 31 Oct 2012 at 4:34

GoogleCodeExporter commented 9 years ago
I tried out your suggestion and the accents problem disappeared, thanks!

Original comment by Josie...@gmail.com on 31 Oct 2012 at 4:35

GoogleCodeExporter commented 9 years ago
Great, thanks!

So that I can understand your problem better (and know what to look for if 
others have a similar problem), can you tell me why you originally had a 
charset="utf-8" meta tag?

Was it your CMS, a mistake, or ...?

Original comment by matterb...@google.com on 31 Oct 2012 at 5:11

GoogleCodeExporter commented 9 years ago
Closing the bug.  If there is an incorrect charset in the meta-tag I think that 
there's not much we can do, though the user can turn off convert_meta_tags.

Original comment by jmara...@google.com on 22 May 2013 at 2:07