function fromFileToArray($file_path, $fields = array(), $num_fields = 0, $method = 1, $params = '') { if (empty($params)) { $params = new DSCParameter(); } $throttled = $params->getValue('throttled_import', false); if ($throttled) { $content = $file_path; } else { // parse whole file $content = file_get_contents($file_path); } // read the file return TiendaCSV::toArray($content, $fields, $num_fields, $method, $params); }