|
@@ 494-496 (lines=3) @@
|
| 491 |
|
$lookup_value = strtolower($lookup_value); |
| 492 |
|
|
| 493 |
|
// lookup_value type has to be number, text, or logical values |
| 494 |
|
if ((!is_numeric($lookup_value)) && (!is_string($lookup_value)) && (!is_bool($lookup_value))) { |
| 495 |
|
return PHPExcel_Calculation_Functions::NA(); |
| 496 |
|
} |
| 497 |
|
|
| 498 |
|
// match_type is 0, 1 or -1 |
| 499 |
|
if (($match_type !== 0) && ($match_type !== -1) && ($match_type !== 1)) { |
|
@@ 512-515 (lines=4) @@
|
| 509 |
|
// lookup_array should contain only number, text, or logical values, or empty (null) cells |
| 510 |
|
foreach($lookup_array as $i => $lookupArrayValue) { |
| 511 |
|
// check the type of the value |
| 512 |
|
if ((!is_numeric($lookupArrayValue)) && (!is_string($lookupArrayValue)) && |
| 513 |
|
(!is_bool($lookupArrayValue)) && (!is_null($lookupArrayValue))) { |
| 514 |
|
return PHPExcel_Calculation_Functions::NA(); |
| 515 |
|
} |
| 516 |
|
// convert strings to lowercase for case-insensitive testing |
| 517 |
|
if (is_string($lookupArrayValue)) { |
| 518 |
|
$lookup_array[$i] = strtolower($lookupArrayValue); |