Re: add default charset
amb-Uxr6IM1mbv2TY6FTCsQk+9Bc4/[email protected] (Andrew M. Bishop) 27 Nov 2006 18:38:51 +0000
| Newsgroups | gmane.network.wwwoffle.user |
|---|---|
| Message-ID | <[email protected]> |
Dan Jacobson <[email protected]> writes: > Not sure what the best way to have the UTF-8 shown correctly in the > Will Get page produced by > > $ for browser in firefox lynx w3m; do > $browser http://radioscanningtw.jidanni.org/index.php?title=%E7%89%B9%E6%AE%8A:Popularpages > done > > Only w3m gets it right. lynx thought it was latin-1 I bet, probably > according to regulations. Firefox guessed it was gb18030. Fiddling > with the doctype didn't help. Adding <meta http-equiv="Content-Type" > content="text/html; charset=utf-8"> did and all browsers got it right. > (Don't just put it in the HEAD, as you don't know just where we will be > processing this output.) The only thing on the page that needs a charset is when WWWOFFLE tries to display the URL-encoded parameters by decoding them and displaying them as raw characters. In the past people have suggested that WWWOFFLE doesn't try to decode them, but just displays them as strings of hex. Perhaps now is a time to reconsider this and stop the decoding. It feels wrong to have a character set specified when there is no reason to suppose that one character set is better than another for this. Obviously for some people URLs will be more likely to contain one character set than another. Most of the page contents for most of the pages are already in the correct character set, it is only the display of URLs that may cause problems. > So WWWOFFLE needs a default charset for the user to configure. > Yes, if one day there's a Big5 URI it will look bad, but at least we > can still adjust things. > > The default charset or charset or whatever it is to be called would be > added to all WWWOFFLE messages, or perhaps a subset, or perhaps per > URL granularity... naw, just all messages for starters. > > Bad to have no facility to override just leaving it up to the winds. The Polish and Russian translations of the WWWOFFLE web pages already specify a character set. It would not make sense to override that with a user specified one so that most of the page content breaks, but the relatively unimportant display of URLs is OK some of the time. If it really bothers you then you can always change the message page templates to have the character set of your choice. -- Andrew. ---------------------------------------------------------------------- Andrew M. Bishop amb-Uxr6IM1mbv2TY6FTCsQk+9Bc4/[email protected] http://www.gedanken.demon.co.uk/ WWWOFFLE users page: http://www.gedanken.demon.co.uk/wwwoffle/version-2.9/user.html