tags:

views:

205

answers:

1

ive got an array like this:

$display_related_tags[0][20] = 'text1';
$display_related_tags[1][21] = 'text2';
$display_related_tags[2][22] = 'text3';

i want to either check if value (text1) exists or if key (20) exists but the mentioned array functions just apply to one dimensional arrays.

what are my alternatives without having to use loops (it will be too heavy then)

+4  A: 

what are my alternatives without having to use loops (it will be too heavy then)

You don't have any other options that to loop (at some level) over the first dimension. The only other way would be to restructure your data.

Yacoby