title: Best way to test if array key exists
body: <p>Imagine that I want to create an array from another array like this:</p>
  
  <pre><code> $array = array('bla' =&gt; $array2['bla'],
                  'bla2' =&gt; $array2['bla2'],
                  'foo' =&gt; $array2['foo'],
                  'Alternative Bar' =&gt; $array['bar'],
                  'bar' =&gt; $array2['bar']);
  </code></pre>
  
  <p>What is the best way to test either the $array2 has that index I'm passing to the other array, without using an if for each index I want to add.</p>
  
  <p>Note that the key from the $array can be different from the $array2</p>