<?php
$objectives_list_param =
Array
(
'J_ID.1' => '02031040080',
'J_Name.1' => 'Review the operation and function of the spoiler system',
'J_Score.1' => '42',
'J_Status.1' => 'F',
'J_ID.2' => '02031040060',
'J_Name.2' => 'Review the operation and function of the primary flight control system',
'J_Score.2' => '95',
'J_Status.2' => 'P',
'J_ID.3' => '03001050010',
'J_Name.3' => 'Identify and determine the oxygen system usage requirements',
'J_Score.3' => '67',
'J_Status.3' => 'F'
);
$objectives_list =
Array
(
'J_ID.1' => '02031040060',
'J_Name.1' => 'Review the operation and function of the primary flight control system',
'J_Score.1' => '',
'J_Status.1' => 'C',
'J_ID.2' => '02031040070',
'J_Name.2' => 'Review the operation and function of the flap and slat system',
'J_Score.2' => '',
'J_Status.2' => 'I',
'J_ID.3' => '02031040080',
'J_Name.3' => 'Review the operation and function of the spoiler system',
'J_Score.3' => '',
'J_Status.3' => 'N'
);
$key = array_search('023031040080', $objectives_list);
if($key === false){
echo 'Key not found';
}else{
echo $key;
}
echo "<br />Last element in array is: " . (string) $array_size(objectives_list);
Key not found
Warning: Undefined variable $array_size in /in/n6otL on line 44
Fatal error: Uncaught Error: Value of type null is not callable in /in/n6otL:44
Stack trace:
#0 {main}
thrown in /in/n6otL on line 44
Process exited with code 255.
Key not found
Notice: Undefined variable: array_size in /in/n6otL on line 44
Fatal error: Uncaught Error: Function name must be a string in /in/n6otL:44
Stack trace:
#0 {main}
thrown in /in/n6otL on line 44
Process exited with code 255.
Output for 7.3.32 - 7.3.33
Key not found
Fatal error: Uncaught Error: Function name must be a string in /in/n6otL:44
Stack trace:
#0 {main}
thrown in /in/n6otL on line 44
Process exited with code 255.
Key not found
Notice: Undefined variable: array_size in /in/n6otL on line 44
Fatal error: Function name must be a string in /in/n6otL on line 44
Process exited with code 255.