Subversion-Projekte lars-tiefland.php_share

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
--TEST--
2
File_CSV Test Case bug14118: Error with quoted fields and separators
3
--FILE--
4
<?php
5
// $Id: bug14118-1.phpt,v 1.2 2008/10/26 21:39:02 dufuz Exp $
6
require_once 'File/CSV.php';
7
$path = dirname(__FILE__) . '/bug14118-1.csv';
8
 
9
$config = array(
10
    'sep'    => ',',
11
    'quote'  => '"',
12
    'fields' => 5
13
);
14
while ($row = File_CSV::read($path, $config)) {
15
    print_r($row);
16
}
17
?>
18
--EXPECT--
19
Array
20
(
21
    [0] => ENFB
22
    [1] => closed
23
    [2] => Oslo, Fornebu
24
    [3] => Airport
25
    [4] =>
26
)
27
Array
28
(
29
    [0] => ENFG
30
    [1] => medium_airport
31
    [2] => Leirin, Leirin
32
    [3] => Airport
33
    [4] =>
34
)