Re: Re: cvs: php4 /ext/standard css.c
| From: | Yasuo Ohgaki | Date: | Sat, 02 Nov 2002 04:49:15 +0000 |
| Subject: | Re: Re: cvs: php4 /ext/standard css.c | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-90440@lists.php.net to get a copy of this message | ||
Ok.
I changed my mind and don't object to make phpinfo() 100% XHTML
compatible as long as UTF-8 is used and chars are converted
reasonably. A few problems will remain, but it will work mostly.
e.g. If input string too short or multiple encodings are mixed,
encoding detection/conversion will not work well. Some encoding
cannot be guessed and user should set php.ini correctly.
When there is something wrong, such as string with wrong/mixed
char encoding, in $_GET/$_POST/$_COOKIE, user should do
<?php
var_dump($_GLOBALS);
?>
instead of using phpinfo().
--
Yasuo Ohgaki
Marcus Boerger wrote:
At 01:40 02.11.2002, Stig S. Bakken wrote:On Wed, 2002-10-09 at 09:35, Yasuo Ohgaki wrote:Colin Viebrock wrote:I really think the best solution (not perfect, but best) is to specify some fonts so the pages look nice, and hard code in the ISO-8859-1 font"hard code in the ISO-8859-1 font" means assuming ISO 8859-1 and use ISO 8859-1 type face by converting chars to entities? Take a look at this page, for example. http://czyborra.com/charsets/iso8859.html Do you see converting text to entity assuming ISO 8859-1 breaks not only multibyte encoding but also other ISO 8859 encoding? I'm well aware of that I'm suggesting to make phpinfo() non XHTML, since it is more useful if it is not confirm XHTML perfectly. If use of HTML entities are preferred, only text that needs HTML entities should use entities. e.g. Names. Isn't using entities for names or like enough? Please no automatic entity conversion assuming ISO 8859-1. Thanks.A bit late, but I'd like to throw in my .02EUR. When dealing with multiple languages, the only reasonable charset to support internally is Unicode, encoded in utf-8. Now, while MSIE supports utf-8, it doesn't sent the Accept-Encoding header. NS4 is AFAIK the only browser that explicitly announces being able to handle utf-8 in the request, but it's not a big issue to figure out if the user agent is from a browser that can deal with utf-8. The "real" solution would be using iconv on the output buffer to change the utf-8 to whatever charset the browser prefers, or if iconv is not available, try converting to 8859-1 and replace characters that don't fit to "?". IMHO this is the only thing that will work for everyone.Since mbstring is better integrated in php i HOPE that will be done by mbstring (and it is not even dependant on another library). marcus