Edit report at https://bugs.php.net/bug.php?id=60494&edit=1

 ID:                 60494
 User updated by:    bin at webcandy dot at
 Reported by:        bin at webcandy dot at
 Summary:            iconv_mime_decode does ignore special characters
 Status:             Open
 Type:               Bug
 Package:            ICONV related
 Operating System:   Windows 7
 PHP Version:        Irrelevant
 Block user comment: N
 Private report:     N

 New Comment:

Expected result should probably have 2 bytes as I expect it to be UTF-8 when 
using iconv.output_encoding = UTF-8

Exptected result:
----------------
string(2) "ä"
string(2) "ö"
string(2) "ß"


Previous Comments:
------------------------------------------------------------------------
[2011-12-11 21:12:35] bin at webcandy dot at

Description:
------------
If the string $text passed to iconv_mime_decode($text) does contain special 
characters (tested with ä, ü and ß), it will just return an empty character 
for these characters.

In my opinion it iconv_mime_decode should leave special characters as they are 
as long as they're not encoded via Q-encoding.

Tested on Windows 7 and Debian.

iconv.output_encoding is set to "UTF-8"

Test script:
---------------
<?php

var_dump(iconv_mime_decode('ä'));
var_dump(iconv_mime_decode('ö'));
var_dump(iconv_mime_decode('ß'));

?>

Expected result:
----------------
string(1) "ä"
string(1) "ö"
string(1) "ß"

Actual result:
--------------
string(0) ""
string(0) ""
string(0) ""


------------------------------------------------------------------------



-- 
Edit this bug report at https://bugs.php.net/bug.php?id=60494&edit=1

Reply via email to