[TYPO3-core] RFC: problem with php4 and xml data with byte order mark

Martin Kutschker Martin.Kutschker at n0spam-blackbox.net
Thu Nov 9 12:21:49 CET 2006


Michael Stucki schrieb:
> 
> There are some problems with this patch:
> 
> - You have renamed $ereg_result to $match, but one line down you didn't
> change that accordingly for $theCharset.

Oops.

> - The preg_match does not work anymore. Tested with PHP 5.1

Strange, I thought it did.

>>Test:
>>include('./class.t3lib_div.php');^
>>$string = "\xEF\xBB\xBF".
>>  '<?xml version="1.0" encoding="utf-8" ?><val>Välué</val>';
> 
> Hmm, that doesn't look like finished, right?

A failed copy'n'paste from my testfile.

> But alright. I have added some more changes and made a new patch, including
> a new test script.

Ah yes, the script contains the missing part.

> The patch works, I tried it with PHP4 and PHP5.1.

Fine.

Masi



More information about the TYPO3-team-core mailing list