Why the last field is ignored when parsing CSV file?

There is a script that parses the CSV file data.

The problem is that the field in the last column is ignored, the script does not see it

CSV FAL as follows:
The category,"item Name";Manufacturer;"Price of product";"Quantity in stock";"Link on the photo (big)";"Link to purchase an item";"Short description";"Full description","the Link to the photo (small)";the Activity's ID
Bigger;"Soft";"Orion";45.94;10;http://www.ez.by/uplo1b167c898391dac19.jpg;http://www.ez.by/soft/;"description...";"a";;on;5663060000


Is the field ID and not processed. If, after the ID to add the"; " separator, that is, make it not the last fields, the data is processed.

How to get process information in the last column?

Thanks in advance.

Script code:
if((($handle = fopen($local, "r")) !== FALSE) && $r) {

 $headers = fgetcsv($handle, 0, ';', '"');

 if ((int) $this->request->post['pointer'] == '0' ) { // If this is the first cycle - reset the amount of product
 if (!$this->request->post['reset_qty']) {
 $this->model_catalog_csvsynchroniz->resetQantity($shopname);//Reset the amount of product
}
}else{
 fseek($handle,$this->request->post['pointer']);// If not the first to expose the pointer to the place where he finished
}

 $k = 0;
 while((($data = $FGetCSV->fgetcsv($handle, 30000, ';', '"')) !== FALSE ) && ($k < $inpart_quantity)) {
 $num = count($data);
 $pairs = array();

 $product_model = $data[$this->request->post['model_number']];

 if ($product_model != ") {
 $p_exist = $this->model_catalog_csvsynchroniz->productExist($product_model, $shopname);//Check the existence of the product

 if ($p_exist->row){// If exists do the update
 $data_old = array();
 $product_id = $p_exist->row['product_id'];
 $update_data = $this->get_data($headers,$data,$num,$product_model,$data_old,$nacenka,$optprice,$this->request->post);// Changing fields from a csv file

$this->model_catalog_csvsynchroniz->updateProduct($update_data,$product_id);
 } 
 /* else { // If not - create a new
 $default_data = $this->default_data($product_model);//Fill default data item
 $add_data = $this->get_data($headers,$data,$num,$product_model,$default_data,$nacenka,$this->request->post);//Change a field from a csv file
$this->model_catalog_product->addProduct($add_data);
 } */
 } 
$k++;
}
 $pointer = ftell($handle);
 $eof_flag = feof($handle) + 0; 
fclose($handle);
 $json['info'] = sprintf($this->language->get("text_updated"), $k+1);
 $json['updated'] = $k;
 $json['pointer'] = $pointer;
 $json['eof_flag'] = $eof_flag;

$this->cache->delete('product');
 } else {

 $json['warning'] = $this->language->get('file_error');

 }
August 23rd 19 at 10:54
0 answer

Find more questions by tags CSV