#30335 [NEW]: fgetcsv + foreign characters

2004-10-06 Thread gruszczol1 at poczta dot onet dot pl
From: gruszczol1 at poczta dot onet dot pl
Operating system: linux
PHP version:  5.0.2
PHP Bug Type: Filesystem function related
Bug description:  fgetcsv + foreign characters

Description:

fgetcsv() doesn't read foreign chracters which are on the beginning of the
field.
Similar bug in http://bugs.php.net/bug.php?id=10896 but it has status
closed.

Reproduce code:
---
File contains:
±abc|¶abc|¿abc¿

Example code:
$aqq=fgetcsv($fp, 4000, |);
echo $aqq[0].$aqq[1].$aqq[2];


Expected result:

Expected result:
±abc¶abc¿abc¿

Actual result:
--
Actual result:
abcabcabc¿

-- 
Edit bug report at http://bugs.php.net/?id=30335edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=30335r=trysnapshot4
Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=30335r=trysnapshot50
Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=30335r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=30335r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=30335r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=30335r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=30335r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=30335r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=30335r=support
Expected behavior:   http://bugs.php.net/fix.php?id=30335r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=30335r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=30335r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=30335r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=30335r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=30335r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=30335r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=30335r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=30335r=float
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=30335r=mysqlcfg


#30335 [Fbk-Opn]: fgetcsv + foreign characters

2004-10-06 Thread gruszczol1 at poczta dot onet dot pl
 ID:   30335
 User updated by:  gruszczol1 at poczta dot onet dot pl
 Reported By:  gruszczol1 at poczta dot onet dot pl
-Status:   Feedback
+Status:   Open
 Bug Type: Filesystem function related
 Operating System: linux
 PHP Version:  5.0.2
 New Comment:

It was tested with iso-8859-2 and windows-1250 text file.
http://republika.pl/gruszczol1/fgetcsv_bug_example.tgz


Previous Comments:


[2004-10-06 10:32:21] [EMAIL PROTECTED]

This example is useles, as we don't know which encoding you are using.
Please put this script in a zip file and provide the link to it in this
bugreport.




[2004-10-06 10:29:45] gruszczol1 at poczta dot onet dot pl

Description:

fgetcsv() doesn't read foreign chracters which are on the beginning of
the field.
Similar bug in http://bugs.php.net/bug.php?id=10896 but it has status
closed.

Reproduce code:
---
File contains:
±abc|¶abc|¿abc¿

Example code:
$aqq=fgetcsv($fp, 4000, |);
echo $aqq[0].$aqq[1].$aqq[2];


Expected result:

Expected result:
±abc¶abc¿abc¿

Actual result:
--
Actual result:
abcabcabc¿





-- 
Edit this bug report at http://bugs.php.net/?id=30335edit=1