We have a csv file like this:
HASTANEKODU,HASTANEADI,SEHIR,BOLGE,DONEM,DONEMKODU,
1128,"SİVAS NUMUNE HASTANESİ",Sivas,"İç Anadolu Bölgesi","KASIM 2010",01
I want to get only text of headers in this csv file as array .I tried this code.
$source = 'uploads/'.$_POST['source'];
$handle = fopen($source, "r");
$data = array();
while( ($line = fgetcsv($handle))) {
$data[] = $line;
}
print_r($data);
But this code get all csv fields.
How can I achive this?
Thanks