title: Store Session Array in Database
body: <p>I have the array-ed session....</p>
  
  <pre><code>$_SESSION['Names'] = array (11,15,26);
  $_SESSION['Location'] = array (35,42,10);
  </code></pre>
  
  <p>and I want to store them in my database...</p>
  
  <pre><code>$que = "Insert into tblpeople (DateTimePosted, first, second, third) VALUES(now(),'$_SESSION['Names'][0], $_SESSION['Location'][0])','$_SESSION['Names'][1], $_SESSION['Location'][1])','$_SESSION['Names'][2], $_SESSION['Location'][2])')";
  $exec = mysql_query($que);
  </code></pre>
  
  <p>After Saving, my database (tblpeople) shows the following values:</p>
  
  <p><strong>DateTimePosted:</strong> <em>2014-01-03 16:23:02</em></p>
  
  <p><strong>first:</strong>  <em>Array[0],Array[0]</em></p>
  
  <p><strong>second:</strong> <em>Array[1],Array[1]</em></p>
  
  <p><strong>third:</strong> <em>Array[2],Array[2]</em></p>
  
  <p>Instead, I want my output to be...</p>
  
  <p><strong>DateTimePosted:</strong> <em>2014-01-03 16:23:02</em></p>
  
  <p><strong>first:</strong>  <em>11,35</em></p>
  
  <p><strong>second:</strong> <em>15,42</em></p>
  
  <p><strong>third:</strong> <em>26,10</em></p>
  
  <p>What's wrong?</p>