Here’s the following array:
Array
(
[1] => Array
(
[0] => 10
[1] => 13
)
[2] => Array
(
[0] => 8
[1] => 22
)
[3] => Array
(
[0] => 17
[1] => 14
)
)
Then I have
$chosenNumber = 17
What I need to know is:
First) if 17 is in the array
Second) the key it has (in this case [0])
Third) the index it belongs (in this case [3])
I was going to use the in_array function to solve first step but it seems it only works for strings ..
Thanks a ton!