title: What is the difference between array_push() and array_merge()?
body: <p>I am adding these two elements into a new array using these two functions <code>array_push()</code> and <code>array_merge()</code>.</p>
  <pre><code>    $a1 = array();
      $a2 = 'foo';
      echo '&lt;pre&gt;';
      print_r( array_merge($a1, (array)$a2) );
      echo '&lt;/pre&gt;';
  </code></pre>
  <p>And with ..</p>
  <pre><code>    $a1 = array();
      $a2 = 'foo';
      array_push($a1, $a2);
      echo '&lt;pre&gt;';
      print_r($a1);
      echo '&lt;/pre&gt;';
  </code></pre>
  <p>all these are printing same..</p>
  <pre><code>Array
   (
      [0] =&gt; foo
   )
  </code></pre>
  <p>Now my question is what is the main difference between these two functions in functionality based. I am new in PHP.</p>