{"thread":{"id":"9085","subject":"Character set for the HTML documentation","startedAt":"2007-07-17T23:31:55Z","lastAt":"2007-07-18T05:26:15Z","messageCount":3,"participants":["H. Peter Anvin","Junio C Hamano","Geoff Richards"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"47684","messageId":"469D516B.6030806@zytor.com","threadId":"9085","inReplyTo":null,"subject":"Character set for the HTML documentation","fromName":"H. Peter Anvin","fromEmail":"hpa@zytor.com","sentAt":"2007-07-17T23:31:55Z","receivedAt":"2007-07-17T23:31:55Z","isPatch":false,"sender":{"key":"hpa@zytor.com","avatar":null},"body":"I just got the following email:\n\n> The Git documentation at\n> <http://www.kernel.org/pub/software/scm/git/docs/user-manual.html> is\n> encoded in ISO 8859-1, but it is being served with a content-type header\n> of \"text/plain; charset=UTF-8\".\n> \n> The content-type header overrides the value declared in the <meta> tag\n> of the HTML document, so this causes browsers to render the\n> documentation incorrectly.\n> \n> Apologies if this is a well known issue and you get a lot of mail like\n> this BTW, just don't LART me too hard. ;)\n\nThe fact that browsers behave this way is of course a bug, but it's a\ncommon one.  Can we switch the documentation over to UTF-8, this is 2007\nafter all...?\n\n\t-hpa\n"},{"id":"47691","messageId":"7vd4yqa2qg.fsf@assigned-by-dhcp.cox.net","threadId":"9085","inReplyTo":"469D516B.6030806@zytor.com","subject":"Re: Character set for the HTML documentation","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2007-07-18T02:02:15Z","receivedAt":"2007-07-18T02:02:15Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"H. Peter Anvin\" <hpa@zytor.com> writes:\n\n> Can we switch the documentation over to UTF-8, this is 2007\n> after all...?\n\nBy all means, yes.\n\nI do not think we particularly wanted to use 8859-1, but nothing\nin Documentation/ tells the asciidoc toolchain that the document\nshould come out in UTF-8 either.\n"},{"id":"47699","messageId":"20070718052615.GA4441@ungwe.org","threadId":"9085","inReplyTo":"469D516B.6030806@zytor.com","subject":"Re: Character set for the HTML documentation","fromName":"Geoff Richards","fromEmail":"qef@ungwe.org","sentAt":"2007-07-18T05:26:15Z","receivedAt":"2007-07-18T05:26:15Z","isPatch":false,"sender":{"key":"qef@ungwe.org","avatar":null},"body":"On Tue, Jul 17, 2007 at 04:31:55PM -0700, H. Peter Anvin wrote:\n> I just got the following email:\n> \n> > The Git documentation at\n> > <http://www.kernel.org/pub/software/scm/git/docs/user-manual.html> is\n> > encoded in ISO 8859-1, but it is being served with a content-type header\n> > of \"text/plain; charset=UTF-8\".\n> > \n> > The content-type header overrides the value declared in the <meta> tag\n> > of the HTML document, so this causes browsers to render the\n> > documentation incorrectly.\n> > \n> > Apologies if this is a well known issue and you get a lot of mail like\n> > this BTW, just don't LART me too hard. ;)\n> \n> The fact that browsers behave this way is of course a bug, but it's a\n> common one.  Can we switch the documentation over to UTF-8, this is 2007\n> after all...?\n\nUnfortunately, it's not a bug.  The correct thing for a browser to do is\ngive the 'Content-Type' HTTP header priority over the <meta> element.\nIt's defined in an RFC somewhere.\n\nBest thing to do is tell Apache (or whatever) not to send the HTTP\nheader (\"AddDefaultCharset off\"), and make sure all the HTML has a\ncorrect <meta> element specifying the encoding.\n\nAnd yes, putting everything in UTF-8 unless you've got a specific reason\nnot to is probably going to make life simpler as well.\n\nHTH,\n   geoff\n"}]}