1
I am uploading a csv file, but it returns the invalid extension error even though the extension is released. I went to look for the cause of the error and found that it is because of a line that is in the file.
if (!$this->upload->do_upload()) {
$this->session->set_flashdata('erro', $this->upload->display_errors());
redirect(base_url() . 'updb/up_numeros/' . $tipo);
exit;
}
Between the lines of the csv file there is one with the following text:
COLUNA 1 COLUNA 2
C TESTE - 6173 2
When I delete the row or include an empty space or any other character in column 1, the upload is successfully performed.
Does anyone have any idea where the mistake might be?