All of lore.kernel.org
 help / color / mirror / Atom feed
From: Geoff Richards <qef@ungwe.org>
To: Git Mailing List <git@vger.kernel.org>
Subject: Re: Character set for the HTML documentation
Date: Wed, 18 Jul 2007 06:26:15 +0100	[thread overview]
Message-ID: <20070718052615.GA4441@ungwe.org> (raw)
In-Reply-To: <469D516B.6030806@zytor.com>

On Tue, Jul 17, 2007 at 04:31:55PM -0700, H. Peter Anvin wrote:
> I just got the following email:
> 
> > The Git documentation at
> > <http://www.kernel.org/pub/software/scm/git/docs/user-manual.html> is
> > encoded in ISO 8859-1, but it is being served with a content-type header
> > of "text/plain; charset=UTF-8".
> > 
> > The content-type header overrides the value declared in the <meta> tag
> > of the HTML document, so this causes browsers to render the
> > documentation incorrectly.
> > 
> > Apologies if this is a well known issue and you get a lot of mail like
> > this BTW, just don't LART me too hard. ;)
> 
> The fact that browsers behave this way is of course a bug, but it's a
> common one.  Can we switch the documentation over to UTF-8, this is 2007
> after all...?

Unfortunately, it's not a bug.  The correct thing for a browser to do is
give the 'Content-Type' HTTP header priority over the <meta> element.
It's defined in an RFC somewhere.

Best thing to do is tell Apache (or whatever) not to send the HTTP
header ("AddDefaultCharset off"), and make sure all the HTML has a
correct <meta> element specifying the encoding.

And yes, putting everything in UTF-8 unless you've got a specific reason
not to is probably going to make life simpler as well.

HTH,
   geoff

      parent reply	other threads:[~2007-07-18  5:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-17 23:31 Character set for the HTML documentation H. Peter Anvin
2007-07-18  2:02 ` Junio C Hamano
2007-07-18  5:26 ` Geoff Richards [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070718052615.GA4441@ungwe.org \
    --to=qef@ungwe.org \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.