|
@@ 784-791 (lines=8) @@
|
| 781 |
|
if($i > 12) { |
| 782 |
|
$data = $row; |
| 783 |
|
$operator = $data[2]; |
| 784 |
|
if ($operator != '' && is_numeric(substr(substr($operator, 0, 3), -1, 1))) { |
| 785 |
|
$airline_array = $Spotter->getAllAirlineInfo(substr($operator, 0, 2)); |
| 786 |
|
//echo substr($operator, 0, 2)."\n";; |
| 787 |
|
if (count($airline_array) > 0) { |
| 788 |
|
//print_r($airline_array); |
| 789 |
|
$operator = $airline_array[0]['icao'].substr($operator,2); |
| 790 |
|
} |
| 791 |
|
} |
| 792 |
|
|
| 793 |
|
$operator_correct = $data[3]; |
| 794 |
|
if ($operator_correct != '' && is_numeric(substr(substr($operator_correct, 0, 3), -1, 1))) { |
|
@@ 794-799 (lines=6) @@
|
| 791 |
|
} |
| 792 |
|
|
| 793 |
|
$operator_correct = $data[3]; |
| 794 |
|
if ($operator_correct != '' && is_numeric(substr(substr($operator_correct, 0, 3), -1, 1))) { |
| 795 |
|
$airline_array = $Spotter->getAllAirlineInfo(substr($operator_correct, 0, 2)); |
| 796 |
|
if (count($airline_array) > 0) { |
| 797 |
|
$operator_correct = $airline_array[0]['icao'].substr($operator_correct,2); |
| 798 |
|
} |
| 799 |
|
} |
| 800 |
|
$query = 'INSERT INTO translation (Reg,Reg_correct,Operator,Operator_correct,Source) VALUES (:Reg, :Reg_correct, :Operator, :Operator_correct, :source)'; |
| 801 |
|
try { |
| 802 |
|
$sth = $Connection->db->prepare($query); |