wilgucki/csv

How To Add Custom Header Column When We Read Csv ?

gurinder-xyrintech opened this issue · 1 comments

i want to add custom header column to my csv something like this

$_csv = \CsvReader::open(storage_path('app/public/attachments/'.$file->file_path)); dd($_csv->setHeader($columns));

Unfortunately there's no such method. Reader allows only to read csv files. If you want to add header you will need to do this on the array returned by readAll method.