To simply check if an array contains a certain value I would do:
{% if myVar in someOtherArray|keys %}
...
{% endif %}
However, my array is multi-dimensional.
$tasks = array(
'someKey' => 'someValue',
...
'tags' => array(
'0' => array(
'id' => '20',
'name' => 'someTag',
),
'1' => array(
'id' => '30',
'name' => 'someOtherTag',
),
),
);
What i would like is to be able to check if the $tasks['tags']
has tag id 20. I hope I'm not confusing you by using the PHP array format.