PHP: Is there a difference between operators AND and && here?
<p>I have the following code and don't think <em>and</em> is needed, i.e. &amp;&amp; should be used, as there is nothing to assign the left part to?</p>

<pre><code>if($_REQUEST['foo'] != 'abc' and $_REQUEST['bar'] == 'def')
{
    echo "all your base";
}
</code></pre>

<p>So it should be:</p>

<pre><code>if($_REQUEST['foo'] != 'abc' &amp;&amp; $_REQUEST['bar'] == 'def')
{
    echo "all your base";
}
</code></pre>
