str_getcsv

(PHP 5 >= 5.3.0)

str_getcsv Parse a CSV string into an array

Description

array str_getcsv ( string $input [, string $delimiter = ',' [, string $enclosure = '"' [, string $escape = '\\' ]]] )

Similar to fgetcsv() this functions parses a string as its input unlike fgetcsv() which takes a file as its input.

Parameters

input

The string to parse.

delimiter

Set the field delimiter (one character only).

enclosure

Set the field enclosure character (one character only).

escape

Set the escape character (one character only). Defaults as a backslash (\)

Return Values

Returns an indexed array containing the fields read.

See Also

  • fgetcsv() - Gets line from file pointer and parse for CSV fields


Copyright © 2010-2024 Platon Technologies, s.r.o.           Index | Man stránky | tLDP | Dokumenty | Utilitky | O projekte
Design by styleshout