[TYPO3-UG Russia] îÏÓÏ×ÍÅÓÔÉÍÏÓÔØ TYPO3 Ó PHP5 ÐÒÉ ÉÓÐÏÌØÚÏ×ÁÎÉÉ windows-1251

Valery Romanchev romanchev at typo3lab.ru
Fri Apr 28 09:15:03 CEST 2006


ðÒÉ×ÅÔ.
õ×Ù - ÎÅÓÏ×ÍÅÔÉÍÁ...
TYPO3 Ó PHP5 ÐÒÉ ÉÓÐÏÌØÚÏ×ÁÎÉÉ force charset windows-1251

é ÒÁÚÒÁÂÏÔÞÉËÉ ÏÂ ÜÔÏÍ ÚÎÁÀÔ...
ÓÍ. class.t3lib_div.php
// PHP5 fix of charset awareness:
   // Problem is: PHP5 apparently detects the charset of the XML file (or
defaults to utf-8) and will AUTOMATICALLY convert the content to either
utf-8, iso-8859-1 or us-ascii. PHP4 just passed the content through without
taking action regarding the charset.
   // In TYPO3 we expect that the charset of XML content is NOT handled in
the parser but internally in TYPO3 instead. Therefore it would be very nice
if PHP5 could be configured to NOT process the charset of the files. But
this is not possible for now.
   // What we do here fixes the problem but ONLY if the charset is utf-8,
iso-8859-1 or us-ascii. That should work for most TYPO3 installations, in
particular if people use utf-8 which we highly recommend.

þÔÏ ÍÏÖÎÏ ÓÄÅÌÁÔØ:
1) ÖÄÁÔØ ÎÕÖÎÏÇÏ ÐÏ×ÅÄÅÎÉÑ ÏÔ  XML ÐÁÒÓÅÒÁ PHP5  (ÇÏÄ?  Á ÍÏÖÅÔ ×ÏÏÂÝÅ ÎÅ
ÓÄÅÌÁÀÔ? )
2) ÓÄÅÌÁÔØ ÐÁÔÞ ÎÁ ËÏÌÅÎËÅ, ÔÉÐÁ
windows-1251-> utf-8 -> xml-ÐÁÒÓÅÒ -> utf-8 -> windows-1251
ô.Å. ÂÕÄÅÔ ÎÅËÏÔÏÒÏÅ ÚÁÍÅÄÌÅÎÉÅ - ÎÅ Õ×ÅÒÅÎ, ÞÔÏ ÔÁË ×ÏÏÂÝÅ ÍÏÖÎÏ
3) ÉÓÐÏÌØÚÏ×ÁÔØ ÄÌÑ PHP5 ÄÒÕÇÏÊ XML ÐÁÒÓÅÒ (DOM ÐÏÍÏÅÍÕ), ËÏÔÏÒÙÊ ÎÏÒÍÁÌØÎÏ
ÐÏÄÄÅÒÖÉ×ÁÅÔ ËÏÄÉÒÏ×ËÉ



÷ÁÌÅÒÉÊ





More information about the TYPO3-russia mailing list