title: PHP - Count the values of an array not the keys?
body: <p>In an array like this:</p>
  
  <pre><code>$array = array(
      'value1'=&gt;'',
      'value2'=&gt;'',
      'value3'=&gt;'',
  );
  </code></pre>
  
  <p>We can:</p>
  
  <pre><code>echo count($array);
  // Outputs 3
  </code></pre>
  
  <p>But if we have an array like:</p>
  
  <pre><code>$array = array(
      'value1'=&gt;'',
      'value2'=&gt;'some value',
      'value3'=&gt;'',
  );
  </code></pre>
  
  <p>What is the best way to do the following?</p>
  
  <pre><code>echo someFunction($array);
  // Outputs 1
  </code></pre>