php function searches an array object for a specific value
<p>I have an array object like this,</p>

<pre><code>Array (
    [0] =&gt; stdClass Object ( [id] =&gt; 247 )
    [1] =&gt; stdClass Object ( [id] =&gt; 248 )
)
</code></pre>

<p>From this, is there any function to check <code>id=222</code> is present or not.</p>

<p>I tried with <code>in_array()</code> and <code>array_search()</code>, it is not working.</p>

<p>Thanks in advance</p>
