[TYPO3-core] Fix bugtracker issue 3172: MIME type determination crashing (HEAD request)

Stanislas Rolland stanislas.rolland at fructifor.ca
Wed Apr 12 23:41:48 CEST 2006


Bernhard Kraft a écrit :
>>> -            fputs($fp,'HEAD '.$getAdr.' HTTP/1.0\r\nHost: 
>>> '.$pathInfo['host'].'\r\n\r\n');
>>> +            fputs($fp,'HEAD '.$getAdr." HTTP/1.0\r\nHost: 
>>> ".$pathInfo['host']."\r\n\r\n");
>>>              while(!feof($fp)) {
>>>                  $thePortion= fgets($fp,128);
>>>                  if (eregi("(^Content-Type: 
>>> )(.*)",trim($thePortion), $reg))    {
>>>
>>
>> alltogether +1 ... but -1 for the above.
>>
>> rather use
>>
>> $thePortion = t3lib_div::getURL($pathInfo['host'].$getAdr, 2);
>>
>> if we have an API we should use it ... 
Attached patch provides a modified version of getMimeType method of 
t3lib_htmlmail.

Regards,
Stanislas

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.netfielders.de/pipermail/typo3-team-core/attachments/20060412/dfcd074e/attachment.htm 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: class.t3lib_htmlmail.php.patch
Url: http://lists.netfielders.de/pipermail/typo3-team-core/attachments/20060412/dfcd074e/attachment.asc 


More information about the TYPO3-team-core mailing list