I got a big array of triggers and condition and i want to extract some of these infos and put in a new array.
Here is a sample of my array:
trigger [
param1 : 'foo',
param2: 'bar',
...
name: 'triggerName',
conditions : [
param1 : 'foo',
param2: 'bar',
value: 3
],
[
param1 : 'foo',
param2: 'bar',
value2: 4
]
],
trigger 2: ...
I want to loop on every trigger & param conditons and extract an associative array which should look like this:
['triggerName' => 3],
['triggerName' => 4]
What's the best way to do this ? By best i mean the faster and the more optimize way !