[dev] [cvs] commit: framework/MIME/MIME Structure.php

Michael M Slusarz slusarz at mail.curecanti.org
Thu Feb 9 07:21:44 PST 2006


Quoting Jan Schneider <jan at horde.org>:

> Zitat von Michael M Slusarz <slusarz at curecanti.org>:
>
>> slusarz     2006-02-08 21:36:36 PST
>>
>>   Modified files:
>>     MIME/MIME            Structure.php
>>   Log:
>>   Use PHP string functions instead of String:: functions since we   
>> are dealing
>>   with MIME headers here - they must be in 7bit.
>>   Only append .0 to rfc822 subparts of 'message'.
>>
>>   Revision  Changes    Path
>>   1.100     +8 -7      framework/MIME/MIME/Structure.php
>
> This is *exactly* why you need the String:: functions here. PHP's
> strto*() functions are locale dependant.

locale dependant how?  are you saying that strto*() treats US-ASCII  
text different depending on the locale?

quite frankly, if there is something non-ASCII contained in a message  
header we *don't ever* want to parse that header.  If that  
header/message doesn't parse correctly, that is a good thing.  e.g. I  
had a test message with 8bit characters in a header and using the  
String:: functions on it screwed up all sorts of stuff.  The correct  
behavior is to have that header remain garbage (and have strto*()  
incorrectly process out) because that's exactly how we should be  
treating that header - as garbage and not useful for anything.

as always, please let me know if i have made incorrect  
assumptions/leaps of faith here.

michael

_______________________________________
Michael Slusarz [slusarz at curecanti.org]


More information about the dev mailing list