I have two arrays.I want to check which is the common element in php
<p>Imgagining i have two array</p>

<pre><code>arr[]={"red","blue","green"}
arr2[]={"red","violet","black"}
</code></pre>

<p>How will i compare the two array to get the result that i common to both of the arrays..</p>

<p>For this the result is red...</p>

<p>How wil i do this in php(simple means)...Can anyone suggest???</p>
