generate functionFri, 27 Jan 2023

import csv from local file and store all line in array. Loop on the array to get all specific columns

$file = fopen("data.csv","r"); while(! feof($file)) { $array[] = fgetcsv($file); } fclose($file); while (list($key, $value) = each($array)) { echo $value[2]; }

Questions about programming?Chat with your personal AI assistant