title: Wordpress: Multi-dimensional Array in post_meta
body: <p>I am trying to make a custom voting plugin for wordpress.</p>
  
  <p>I want to use post_meta to store the data.
  It should have two sets of informations (user_id and a timestamp) for every vote in every post. 
  So I set up an array with the data: </p>
  
  <pre><code>$up_vote = Array(
  'ls_user_id' =&gt; $current_user-&gt;ID,
  'ls_timestamp' =&gt; current_time('mysql')
  );
  </code></pre>
  
  <p>The data inside the post_meta should be an Array of these Arrays.
  To do this, I first create an empty Array, get the old data, and then push my first array inside like this:</p>
  
  <pre><code>$ls_up_votes = Array();
  $ls_up_votes = get_post_meta(get_query_var('ls_id'), 'ls_up_votes');
  array_push($ls_up_votes, $up_vote);
  </code></pre>
  
  <p>And later I store it like this:</p>
  
  <pre><code>update_post_meta(get_query_var('ls_id'), 'ls_up_votes', $ls_up_votes);
  </code></pre>
  
  <p>Now the problem:
  Always when I try to get the data (and work with it), it gives me an Array which has only one element (sizeof() returns 1).</p>
  
  <p>How can I store a multi-dimensional Array here?
  What am I doing wrong?</p>
  
  <p>thanks for your time! :)</p>