title: How can I create an array from the values of another array's key?
body: <p>I have an array as follows:</p>
  <pre><code>$arr1 = array(
    0 =&gt; array(
      'name' =&gt; 'tom',
      'age' =&gt; 22
    ),
    1 =&gt; array(
      'name' =&gt; 'nick',
      'age' =&gt; 18
    )
  );
  </code></pre>
  <p>However I want to create an array from it which consists of all the names, so it would become:</p>
  <pre><code>$arr2 = array('tom', 'nick');
  </code></pre>
  <p>I have looked at <code>array_filter()</code>, but that would not work as this is a multi-dimensional array!</p>
  <h1>Question</h1>
  <p>How can I create an array with the values of a specific key (<code>name</code>) from another multi-dimensional array?</p>